• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Dialog Buttons

Status
Not open for further replies.
Level 5
Joined
Sep 10, 2006
Messages
185
There's the event "A button is clicked for ____"

Anyway to refer to the player who clicked it in "Display message for ____"?

What I'm doing now is when you bring up the dialog, the player is added to a player group. When a button is clicked, the message is displayed to the group and the triggering player is removed. This works fine except other people see your message if you have the dialog box open.
 
Level 3
Joined
Apr 20, 2010
Messages
46
It would be easier to understand if you provided the trigger code.

Messages are displayed to a force in GUI to my knowledge.

  • Game - Display to (Player group((Triggering player))) the text: (Message Here)
 
Level 5
Joined
Sep 10, 2006
Messages
185
  • /Dialogclick
    • Events
      • Dialog - A dialog button is clicked for ArmorDialog
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogCancel
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogDivine
        • Then - Actions
          • Game - Display to Button the text: Units with Divine A...
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogFlying
        • Then - Actions
          • Game - Display to Button the text: Units with Flying A...
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogHero
        • Then - Actions
          • Game - Display to Button the text: Units with Hero arm...
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogMagic
        • Then - Actions
          • Game - Display to Button the text: Units with Magic ar...
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogMech
        • Then - Actions
          • Game - Display to Button the text: Units with Mechanic...
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogPhysical
        • Then - Actions
          • Game - Display to Button the text: Units with Physical...
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogUnarmored
        • Then - Actions
          • Game - Display to Button the text: Unarmored units tak...
        • Else - Actions
      • Dialog - Clear ArmorDialog
      • Player Group - Remove (Triggering player) from Button
No triggering player for display to.
 
Level 3
Joined
Apr 20, 2010
Messages
46
  • Dialog Click
    • Events
      • Dialog - A dialog button is clicked for ArmorDialog
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogCancel
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to DialogDivine
        • Then - Actions
          • Game - Display to (Player group((Triggering player))) the text: (Message Here)
        • Else - Actions
"Dialog - A dialog button is clicked" has always picked up Triggering Player in my experience.
 
Last edited:
Status
Not open for further replies.
Top