Game Time Return Value

Chewbalka

New Member
Reaction score
14
Trigger:
  • Player Leaves Building
    • Events
    • Conditions
    • Actions
      • Set GameREAL[1] = (In-game time of day)
      • Set PlayerBOOLEAN[1] = False
        • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • GameREAL[1] Greater than or equal to (>=) 6.00
            • GameREAL[1] Less than or equal to (<=) 18.00
          • Then - Actions
            • Trigger - Run In Game Time 6 <gen> (checking conditions)
            • Game - Display to (All players) the text: 1
          • Else - Actions
        • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • GameREAL[1] Greater than or equal to (>=) 18.00
            • GameREAL[1] Less than or equal to (<=) 6.00
          • Then - Actions
            • Trigger - Run In Game Time 18 <gen> (checking conditions)
            • Game - Display to (All players) the text: 1
          • Else - Actions
      • Game - Display to (All players) the text: 2


This trigger was made to set the Fog setting after a player leaves a building, i also have one for when they enter (almost the same thing as above, also doesent work). the problem is when it is runs it says '2' meaning all conditions are false, technicly its impossible unless when you use a variable to collect time of day it does not return as a REAL from 0-24

what would my condition have to be to have this work?
 

cleeezzz

The Undead Ranger.
Reaction score
268
the display 2 is outside the if loops which means it will run no matter if conditions are met or not.

go to the game constants to see how long each day is. and when day and night start
 

cleeezzz

The Undead Ranger.
Reaction score
268
are you sure the boolean is false? make a game message to display that it actually passes the boolean.

and like i said, go to the advanced tab, game constants nad you can see the hours of the day.
 

Artificial

Without Intelligence
Reaction score
326
Code:
GameREAL[1] Greater than or equal to (>=) 18.00
GameREAL[1] Less than or equal to (<=) 6.00
Now tell me which number is less than or equal to 6 but still greater than or equal to 18.

You should either wrap the conditions in the second if/then/else inside an 'Or', or you could just use the 'Else' actions of the first if/then/else:
Trigger:
  • Player Leaves Building
    • Events
    • Conditions
    • Actions
      • Set GameREAL[1] = (In-game time of day)
      • Set PlayerBOOLEAN[1] = False
        • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • GameREAL[1] Greater than or equal to (&gt;=) 6.00
            • GameREAL[1] Less than or equal to (&lt;=) 18.00
          • Then - Actions
            • Trigger - Run In Game Time 6 &lt;gen&gt; (checking conditions)
            • Game - Display to (All players) the text: 1
          • Else - Actions
            • Trigger - Run In Game Time 18 &lt;gen&gt; (checking conditions)
            • Game - Display to (All players) the text: 1
      • Game - Display to (All players) the text: 2
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      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