• 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.

Can i make a hero spawn only for player name ?

Status
Not open for further replies.
Level 4
Joined
Oct 14, 2008
Messages
67
Hi there!

I got a problem with my map. i got a dialog showen when entring game where you choose your hero, but i want the dialog to add one more line with a secret hero only for me (quazaka) and Xiroc can choose

Thanks!
 
Level 5
Joined
Jan 3, 2008
Messages
164
Well, here is the trigger I wrote for you, but you will have to add your own dialog triggers to it ^^
  • Special
    • Events
      • Time - Elapsed game time is 10.00 seconds
    • Conditions
    • Actions
      • Set AllPlayers = (All players)
      • Player Group - Pick every player in AllPlayers and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • (Name of (Picked player)) Equal to Quazaka
                  • (Name of (Picked player)) Equal to Xiroc
            • Then - Actions
              • Player Group - Add (Picked player) to SpecialPlayers
              • Player Group - Pick every player in SpecialPlayers and do (Actions)
                • Loop - Actions
                  • -------- Special Dialog --------
                  • Dialog - Show SpecialDialog for (Picked player)
            • Else - Actions
              • Player Group - Pick every player in (All players matching (((Matching player) is in SpecialPlayers) Equal to False)) and do (Actions)
                • Loop - Actions
                  • -------- Normal Dialog --------
                  • Dialog - Show NormalDialog for (Picked player)
      • Custom script: Call DestroyForce(udg_AllPlayers)
It's not that hard actually.. For the conditions thing, from the drop down menu (type of condition) chose String Comparison and then Player - Player Name. Hope that helped :wink:
 
Level 4
Joined
Oct 14, 2008
Messages
67
Well, here is the trigger I wrote for you, but you will have to add your own dialog triggers to it ^^
  • Special
    • Events
      • Time - Elapsed game time is 10.00 seconds
    • Conditions
    • Actions
      • Set AllPlayers = (All players)
      • Player Group - Pick every player in AllPlayers and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • (Name of (Picked player)) Equal to Quazaka
                  • (Name of (Picked player)) Equal to Xiroc
            • Then - Actions
              • Player Group - Add (Picked player) to SpecialPlayers
              • Player Group - Pick every player in SpecialPlayers and do (Actions)
                • Loop - Actions
                  • -------- Special Dialog --------
                  • Dialog - Show SpecialDialog for (Picked player)
            • Else - Actions
              • Player Group - Pick every player in (All players matching (((Matching player) is in SpecialPlayers) Equal to False)) and do (Actions)
                • Loop - Actions
                  • -------- Normal Dialog --------
                  • Dialog - Show NormalDialog for (Picked player)
      • Custom script: Call DestroyForce(udg_AllPlayers)
It's not that hard actually.. For the conditions thing, from the drop down menu (type of condition) chose String Comparison and then Player - Player Name. Hope that helped :wink:


Okay thanks but how do i make the (Name of (Picked player)) Equal to Quazaka????? Im new for the map making ? :)
 
Level 5
Joined
Jan 3, 2008
Messages
164
I have already explained that in my last post... well, I will repeat it again.
Right click and chose "New Condition"
From the drop down menu choose "String Comparison"
Click on "(Entered chat string)"
From the drop down menu choose "Player - Player Name"
And then you should know how to do it..
 
Level 4
Joined
Oct 14, 2008
Messages
67
Okay thanks.... i got that one, but what about the last custom script you got ? :S Im very new for mapmaking
 
Level 12
Joined
Apr 27, 2008
Messages
1,228
Well, here is the trigger I wrote for you, but you will have to add your own dialog triggers to it ^^
  • Special
    • Events
      • Time - Elapsed game time is 10.00 seconds
    • Conditions
    • Actions
      • Set AllPlayers = (All players)
      • Player Group - Pick every player in AllPlayers and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • (Name of (Picked player)) Equal to Quazaka
                  • (Name of (Picked player)) Equal to Xiroc
            • Then - Actions
              • Player Group - Add (Picked player) to SpecialPlayers
              • Player Group - Pick every player in SpecialPlayers and do (Actions)
                • Loop - Actions
                  • -------- Special Dialog --------
                  • Dialog - Show SpecialDialog for (Picked player)
            • Else - Actions
              • Player Group - Pick every player in (All players matching (((Matching player) is in SpecialPlayers) Equal to False)) and do (Actions)
                • Loop - Actions
                  • -------- Normal Dialog --------
                  • Dialog - Show NormalDialog for (Picked player)
      • Custom script: Call DestroyForce(udg_AllPlayers)
It's not that hard actually.. For the conditions thing, from the drop down menu (type of condition) chose String Comparison and then Player - Player Name. Hope that helped :wink:

You do NOT destroy All players - game crash. Besides it does not leak.
This is better:
  • Special
    • Events
      • Time - Elapsed game time is 10.00 seconds
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • (Name of (Picked player)) Equal to Quazaka
                  • (Name of (Picked player)) Equal to Xiroc
            • Then - Actions
              • Dialog - Show SpecialDialog for (Picked player)
            • Else - Actions
              • Dialog - Show NormalDialog for (Picked player)
 
Level 4
Joined
Oct 14, 2008
Messages
67
Thanks Alot!

Btw, do this work for LAN ? If eny one call himself Quazake all will get anable to pick the hero? ;P
 
Status
Not open for further replies.
Top