• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Trigger] Can't figure out why Dialog isn't showing.

Status
Not open for further replies.
Level 6
Joined
Dec 9, 2014
Messages
176
So everything has been working great up to this point where a dialog box is supposed to be created and then shown in order to continue the conversation. It has no problem displaying the game message but the dialog box that's supposed to show right after, just isn't. The bit that isn't working is at the very bottom. Any help as to why would be much appreciated.

  • Buckley Diag 1
    • Events
      • Dialog - A dialog button is clicked for BuckleyIntroDiag[1]
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to BuckleyDiagButton[1]
        • Then - Actions
          • Game - Display to Player Group - Player 1 (Red) the text: (CharacterName[1] + :"Just passing through. Trying to find the Citadel of Argartharis.")
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • BuckleyPork Equal to 0
            • Then - Actions
              • Game - Display to Player Group - Player 1 (Red) the text: |cff7777aaBuckley|r...
              • Item - Create Roasted Pork at (Position of Buckley |cffffcc002|r 0002 <gen>)
              • Item - Set charges remaining in (Last created item) to 2
              • Set BuckleyPork = 1
              • Unit - Unpause all units
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • BuckleyPork Equal to 1
                • Then - Actions
                  • Unit - Unpause all units
                  • Game - Display to Player Group - Player 1 (Red) the text: |cff7777aaBuckley|r...
                • Else - Actions
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to BuckleyDiagButton[2]
        • Then - Actions
          • Game - Display to Player Group - Player 1 (Red) the text: |cff7777aaBuckley|r...
          • Unit - Unpause all units
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to BuckleyDiagButton[3]
        • Then - Actions
          • Game - Display to Player Group - Player 1 (Red) the text: |cff7777aaBuckley|r...
          • Dialog - Create a dialog button for BuckleyIntroDiag[2] labelled "Yeah, we got him p...
          • Set BuckleyDiagButton[4] = (Last created dialog Button)
          • Dialog - Create a dialog button for BuckleyIntroDiag[2] labelled "Yeah, he sent me o...
          • Set BuckleyDiagButton[5] = (Last created dialog Button)
          • Wait 5.00 seconds
          • Dialog - Show BuckleyIntroDiag[2] for Player 1 (Red)
        • Else - Actions
 
Last edited:
Dialog[2]: did you set array size in variable Editor to 2, if not Dialog [2] does not exist and can not contain buttons and neither be shown.

You have to create more advanced datatypes before beeing able to use them, if the editor has not created them for you.
So Dialog is one of this advanced datatypes, if you used the default array size 1; only Dialog[0] and Dialog[1] are existing.

Change Arraysize in variable Editor to 2, then Dialog[2] will be auto created and your trigger should work.

Edit: the buttons are fine with size 1, cause you use this create Button function.
 
Level 6
Joined
Dec 9, 2014
Messages
176
Oh wow, the array is only set to one. I didn't realize it the array was set so low. Hell, I completely forgot that it doesn't just give you infinite arrays to begin with lol. Thanks so much! I'm afraid the buttons may mess up in future dialogs if I use the same arrays repeatedly. I guess not now that I think about the fact that I'm setting the cuttons as I go. I'll do that for the buttons from now on rather than using more an more arrays.
 
Status
Not open for further replies.
Top