Timed Dialog problem!

Menelaus

New Member
Reaction score
9
Ok I have a dialog for a td and u choose the difficulty and it works fine except for one part. I want it to be hidden after 30 secs and start the game w/ 25 lives (in case red isnt there or takes too long). wait 30 secs doesnt work, and neither does a timer or seperate triggers. Is there any way to do it????
 

Menelaus

New Member
Reaction score
9
Oh yeah sry duh....

Trigger: lives dialog
Code:
   Events-
 Elapsed game time is 0.10 secs
   Condits-
   Actions-
 dialog-Clear lives_dialog
 dialog-Change the title of lives_dialog
 dialog-create dialog button for lives dialog labelled 1
 set lives_dialog_button[1] = last created dialog button
 dialog-create dialog button for lives dialog labelled 5
 set lives_dialog_button[2] = last created dialog button
 dialog-create dialog button for lives dialog labelled 10
 set lives_dialog_button[3] = last created dialog button
 dialog-create dialog button for lives dialog labelled 20
 set lives_dialog_button[4] = last created dialog button
 dialog-create dialog button for lives dialog labelled 50
 set lives_dialog_button[5] = last created dialog button
 dialog-create dialog button for lives dialog labelled 1000
 set lives_dialog_button[6] = last created dialog button
 dialog-show lives_dialog for primary_player (a variable i defined as: if red wasnt there, then blue, if blue wasnt there, then teal, etc.)
 Game-display to all players for 29.90 secs the text: Player name has 30......
 Wait 30 secs
 dialog- hide  lives_dialog for primary_player
 If all condits are true, then do (actions) else do (actions)
    IF Conditions-Footman 15 is alive equal to true
    THEN Actions- Kill footman 15
                        set lives = 25
                        Game display to all players the text: Player name took 30...
    ELSE Actions- Do nothing

**Footman 15 is the event for the next set of triggers
TRIGGER: button clicked
Code:
   Events- Dialog- A button is clicked for lives_dialog
   Condits-
   Actions- For each integer a from 1 to 6 then do actions else do actions
          Loop-Actions
                 If, then else
                 IF Condits- Clicked dialog button equal to lives_dialog_button[integer a]
                 THEN Actions- set lives = setup lives[integer a]
                  Game- display to Players_in_game the text: lives_message[integer a]
                  Leaderboard-change the value for hostile_creeps in kills_board to lives
                  Unit-Kill Footman 15
                  ELSE-

TRIGGER: lives setup
Code:
Events-map init
 Condits-
 Actions- Set setup_lives[1] = 1
 Set setup_lives[2] = 5
 Set setup_lives[3] = 10
 Set setup_lives[4] = 20
 Set setup_lives[5] = 50
 Set setup_lives[6] = 1000
 Set lives_message[1] = blah blah blah
 Set lives_message[2] = blah blah blah  
 Set lives_message[3] = blah blah blah     
 Set lives_message[4] = blah blah blah
 Set lives_message[5] = blah blah blah
 Set lives_message[6] = blah blah blah
 
O

OneEight7eve

Guest
lol? did you type that you know you can right click > copy as text

id rather see exact trigger cause urs is so much
 

Menelaus

New Member
Reaction score
9
...

wow thats helpful!!!!!
ok


Code:
dialog lives
    Events
        Time - Elapsed game time is 0.10 seconds
    Conditions
    Actions
        Dialog - Clear lives_dialog
        Dialog - Change the title of lives_dialog to Select the number o...
        Dialog - Create a dialog button for lives_dialog labelled 1 |cffff0000 (Exper...
        Set lives_dialog_button[1] = (Last created dialog Button)
        Dialog - Create a dialog button for lives_dialog labelled 5 |cffff4500 (Pro)|...
        Set lives_dialog_button[2] = (Last created dialog Button)
        Dialog - Create a dialog button for lives_dialog labelled 10 |cffffff00 (Expe...
        Set lives_dialog_button[3] = (Last created dialog Button)
        Dialog - Create a dialog button for lives_dialog labelled 20 |cff00ff2f (Play...
        Set lives_dialog_button[4] = (Last created dialog Button)
        Dialog - Create a dialog button for lives_dialog labelled 50 |cff00ff00 (Newc...
        Set lives_dialog_button[5] = (Last created dialog Button)
        Dialog - Create a dialog button for lives_dialog labelled 1000 |cffffffff (NO...
        Set lives_dialog_button[6] = (Last created dialog Button)
        Dialog - Show lives_dialog for primary_player
        Game - Display to (All players) for 29.90 seconds the text: ((Name of primary_player) +  has 30 seconds to pick the number of lives.)
        Wait 30.00 seconds
        Dialog - Hide lives_dialog for primary_player
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Footman 0015 <gen> is alive) Equal to True
            Then - Actions
                Unit - Kill Footman 0015 <gen>
                Set lives = 25
                Game - Display to (All players) the text: ((Name of primary_player) +  didn't choose his lives fast enough... You have 25 lives.)
            Else - Actions
                Do nothing

Code:
lives clicked button
    Events
        Dialog - A dialog button is clicked for lives_dialog
    Conditions
    Actions
        For each (Integer A) from 1 to 6, do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        (Clicked dialog button) Equal to lives_dialog_button[(Integer A)]
                    Then - Actions
                        Set lives = setuplives[(Integer A)]
                        Game - Display to players_in_game the text: lives_message[(Integer A)]
                        Leaderboard - Change the value for hostile_creeps in kills_board to lives
                        Unit - Kill Footman 0015 <gen>
                    Else - Actions
Code:
lives dialog setup
    Events
        Map initialization
    Conditions
    Actions
        Set setuplives[1] = 1
        Set setuplives[2] = 5
        Set setuplives[3] = 10
        Set setuplives[4] = 20
        Set setuplives[5] = 50
        Set setuplives[6] = 1000
        Set lives_message[1] = (You better be experts! + ((Name of Player 1 (Red)) +  has set the lives to just one.))
        Set lives_message[2] = (((Name of Player 1 (Red)) +  thinks you are pretty good (pros).  Only five lives may be lost.) +  )
        Set lives_message[3] = (((Name of Player 1 (Red)) +  has set the number of lives to ten.  ) + He or she thinks you are experienced players.)
        Set lives_message[4] = (((Name of Player 1 (Red)) +  assumes you've played a couple of TDs before or have a good sense for the game.  ) + He or she has set the lives to twenty.)
        Set lives_message[5] = (You probably revealed the fact that some of you are newcomers. + ((Name of Player 1 (Red)) +  has set the lives to fifty.))
        Set lives_message[6] = (Either the host is an asshole or you guys suck. + ((Name of Player 1 (Red)) +  has set the lives to one thousand.  If you're good, you might want to consider leaving...))

well that only took 3 mins..... but still thx
 
O

OneEight7eve

Guest
Time - Elapsed game time is 30.00 seconds ?? would that jus work . sorry for takin so long 4got about u
 

OneBadPsycho

10100111001
Reaction score
93
Code:
DialogWait
    Events
        Time - Elapsed game time is 30.00 seconds
    Conditions
    Actions
        Dialog - Hide (Dialog) for Player 1 (Red)

Wouldnt that work?
 

OVRKLL

New Member
Reaction score
3
So timers freeze when a dialog appears? Or what's the lesson to learn here?
 

Menelaus

New Member
Reaction score
9
So does that mean that my original code will work on bnet but just not on single player?
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though
  • Ghan Ghan:
    Heard Houston got hit pretty bad by storms last night. Hope all is well with TH.
  • The Helper The Helper:
    Power back on finally - all is good here no damage
    +2
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    New recipe is another summer dessert Berry and Peach Cheesecake - https://www.thehelper.net/threads/recipe-berry-and-peach-cheesecake.194169/

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top