• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!

Dialog problems! plz help me

Status
Not open for further replies.
Level 2
Joined
Oct 4, 2004
Messages
5
hi... please help me....

i made a dialog and it is being shown to the players, but when the player press a button for ex. "Human" there should spawn a Peasant. I tried many things but i cant make a peasant spawn.


My Triggers:

------------------------------------------------------------------------
1st trigger:

Events:
--- Time - Elasped game time is 2.00 seconds
conditions:
--- -
actions:
--- Dialog - Create a Dialog button for "Variable1" labelled "Human"
--- Dialog - Show "Variable1" for "Player 1" (Red)

------------------------------------------------------------------------
2nd trigger

Events:
--- Dialog - A dialog button is clicked for "Variable1"
Conditions:
--- (Clicked dialog button) equal to "Human"
Actions:
--- Unit - Create 1 peasant for (Picked player) at ((Picked player) start location) facing ((Picked player) start location)

------------------------------------------------------------------------

plz help me! :cry: :lol:
 
Level 4
Joined
Aug 31, 2004
Messages
106
the problem is that you did not assign a variable to the dialog button. when you do that, change the condition in trigger 2 to "condition: clicked dialog button equal to <your variable>.
This is a common problem. Try to find a little more out about something before posting a question here.[/code]
 
Level 13
Joined
May 5, 2004
Messages
1,330
Unit - Create 1 peasant for (Picked player) at ((Picked player) start location) facing ((Picked player) start location)

You can't use "picked player" for this action. "picked player" always refers to the "player - pick all players..."-action. Try using "Event Response - Triggering Player". I'm not quite sure though.
 
Level 2
Joined
Oct 4, 2004
Messages
5
ok now i changed it and it still doesnt work..

My Triggers:

------------------------------------------------------------------------
1st trigger:

Events:
--- Time - Elasped game time is 2.00 seconds
conditions:
--- -
actions:
--- Dialog - Create a Dialog button for "Variable1" labelled "Human"
--- Dialog - Show "Variable1" for "Player 1" (Red)

------------------------------------------------------------------------
2nd trigger

Events:
--- Dialog - A dialog button is clicked for "Variable1"
Conditions:
--- (Clicked dialog button) equal to "Human"
Actions:
--- Unit - Create 1 peasant for (Picked player) at ((Picked player) start location) facing ((Picked player) start location)... i still dont know what to do here.. i cant find that event responce...

------------------------------------------------------------------------

variable1: i made this in the variables menu.. and i made the initial value to "New dialog button"
variable2: i made this initial value to "last created dialog button"-... as i was told in another turioal...

------------------------------------------------------------------------

if somebody knows how to make a dialog appear and when i press, there will spawn a "unit" at a "location"... plz show me
 
Level 13
Joined
Jan 9, 2004
Messages
1,037
td-proo said:
--- Dialog - Create a Dialog button for "Variable1" labelled "Human"
--- Dialog - Show "Variable1" for "Player 1" (Red)

That's where your problem lies. Like birdofprey160 said, you didnt assign the button to the variable. So, it should say

--- Dialog - Create a Dialog button for "Variable1" labelled "Human"
--- Set "Variable2" = Last Created Dialog Button
--- Dialog - Show "Variable1" for "Player 1" (Red)

EDIT: Oh, and I'm not sure where you got Human from here:
Conditions:
--- (Clicked dialog button) equal to "Human"
That should be "Variable2".
 
Level 4
Joined
Oct 8, 2004
Messages
64
dialog

First Trigger:

Event: time elapsed 2 sec

Dialog - Change the title of Player_choose_unit to "Choose a unit"
Dialog - Create a dialog button for Player_choose_unit labelled "human"
Set user_chose_human_Btn = (Last created dialog Button)
Dialog - Show Player_choose_unit for Player 1 (Red)

Second Trigger:

Event: Dialog - A dialog button is clicked for Player_choose_unit

Condition: (Clicked dialog button) Equal to user_chose_human_Btn

Actions: create 1 unit blah blah blah...

Dialog - Clear Player_choose_unit
 
Status
Not open for further replies.
Top