• 🏆 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 37
Joined
Mar 6, 2006
Messages
9,240
Yes, with DialogAddButton().

I'm assuming you're using GUI.

Let's also assume that there is a dialog variable called Dialog and a dialog button variable called buttons, and that variable is an array.

  • Custom script: set udg_buttons[1] = DialogAddButton( udg_Dialog , "Text - [Q]" , 'Q' )
This would make the buttons[1] to say

Text - [Q]

and it would be selected when you press Q.

You can make it work with enter I believe.
 
Last edited:
Level 9
Joined
Jun 7, 2008
Messages
440
I seen this function in Jass. Though, What I was really wanting was to make it so no keys would be attached. Would I be able to use "null" in that instance?
JASS:
    set buttons[1] = DialogAddButton(dialog, "start", null)

Would this work?
 
Status
Not open for further replies.
Top