• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

1 of my last questions

Status
Not open for further replies.
Level 9
Joined
Aug 1, 2008
Messages
453
How do i make a thing thats kinda like this. a unit enters a region and it says

(Players Name) has enter left arena they can leave in 60 seconds how do i make it so it displays there names? Please and thank you ^^
 
Level 5
Joined
Jul 4, 2008
Messages
111
I think this is how but maybe u should try checking if u could use String 1 + 2 but i haven't tried it (String 1 and 2 is found when u click on wat u want the text to be)))) Hope it helps :D
  • Events
  • A unit enters Region 001
  • Conditions
  • (Owner of (Entering unit)) Equal to Player 1 (Red)
  • Actions
  • Game - Display to (All players) the text: Red has entered region
 
Level 6
Joined
Sep 13, 2008
Messages
261
In the display string options it has player name as an option. Just use game message concacenate strings Player Name + Your Message.

  • Untitled Trigger 001
    • Events
      • Unit - A unit enters (Entire map)
    • Conditions
    • Actions
      • Game - Display to (All players) for 30.00 seconds the text: ((Name of (Owner of (Triggering unit))) + has entered the arena.)
 
Level 7
Joined
Sep 9, 2007
Messages
253
  • Untitled Trigger 001
    • Events
      • Unit - A unit enters Left Arena Entrance <gen>
    • Conditions
      • ((Entering unit) is A Hero) Equal to True
    • Actions
      • Game - Display to (All players) the text: ((Name of (Owner of (Entering unit))) + has entered the left arena.)
I'm a noob at finding leaks, I have no idea if this action would have any.
Is this what you wanted?

As a side note if you want the name to be in the players colour I have done this before using a string variable array which sets their string (including colour tags) upon choosing their hero.

  • Hero Purchase and Setup
    • Events
      • Unit - A unit Sells a unit
    • Conditions
      • ((Unit-type of (Selling unit)) Equal to Tavern 1) or ((Unit-type of (Selling unit)) Equal to Tavern 2)
    • Actions
      • -------- Set player_string --------
      • Set Player_String[(Player number of (Owner of (Sold unit)))] = (Name of (Owner of (Sold unit)))
      • Set Player_String_Coloured[1] = (|c00FF0303 + (Player_String[1] + |r))
      • Set Player_String_Coloured[2] = (|c000042FF + (Player_String[2] + |r))
      • Set Player_String_Coloured[3] = (|c001CE6B9 + (Player_String[3] + |r))
      • Set Player_String_Coloured[4] = (|c00540081 + (Player_String[4] + |r))
      • Set Player_String_Coloured[5] = (|c00FFFC01 + (Player_String[5] + |r))
      • Set Player_String_Coloured[6] = (|c00fEBA0E + (Player_String[6] + |r))
      • -------- Set hero_string --------
      • Set Hero_String[(Player number of (Owner of (Sold unit)))] = (Name of (Sold unit))
      • Set Hero_String_Coloured[1] = ( |c00FF0303( + (Hero_String[1] + )|r))
      • Set Hero_String_Coloured[2] = ( |c000042FF( + (Hero_String[2] + )|r))
      • Set Hero_String_Coloured[3] = ( |c001CE6B9( + (Hero_String[3] + )|r))
      • Set Hero_String_Coloured[4] = ( |c00540081( + (Hero_String[4] + )|r))
      • Set Hero_String_Coloured[5] = ( |c00FFFC01( + (Hero_String[5] + )|r))
      • Set Hero_String_Coloured[6] = ( |c00fEBA0E( + (Hero_String[6] + )|r))
Of course these actions need conditions otherwise it will set all players names to whoever last picked a hero.

then use this action when a hero enters your region
  • Game - Display to (All players) the text: (Player_String_Coloured[(Player number of (Owner of (Entering unit)))] + Hero_String_Coloured[(Player number of (Owner of (Entering unit)))] + has entered the left arena.)

I'm sure there's a more efficient way of doing that but It works. Anybody care to point out leaks in my triggers?
 
Last edited:
Status
Not open for further replies.
Top