• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Day of the week trigger- problems.

Status
Not open for further replies.
Level 5
Joined
Jun 18, 2007
Messages
68
Here is what I'm trying to do. At 24.00 the game time changes the day(integer value). For example intially its monday. At 24.00 it changes to tuesday. I'm having trouble doing this-below is my triggers...

Here is what I have:

This is what day of the week is set first.

  • Start Up
  • Events
    • Map initilization
  • Conditions
  • Actions
    • Game - set Time of day to 1.00
    • Game - set time of day speed to 3000.00% of the defualt speed
    • Set days[1]=1

This is what happens when it reaches 24.00


  • Monday
  • Events
    • Game - The in-game time of day becomes Equal to 24.00
  • Conditions
    • days[1] Equal to 1
  • Actions
    • Game - display to (All Players) the text: monday
    • Set days[2] Equal to 2
    • Trigger - Turn on tuesday
    • Trigger -Turn off (This Trigger)
Here is the problem. Tuesday is never displayed on the screen.


  • Tuesday
  • Events
    • Game - The in-game time of day becomes Equal to 24.00
  • Conditions
    • days[2] Equal to 2
  • Actions
    • Game - display to (All Players) the text: tuesday
    • Set days[3] Equal to 3
    • Trigger - Turn on wednesday
    • Trigger - Turn off (This Trigger)

After this I have similar triggers for each day of the week. Even one that turns on monday again. But only trigger that displays monday seems to be working. Any help would be grateful, thanks!
 
Level 21
Joined
Aug 21, 2005
Messages
3,699
  • Untitled Trigger 001
    • Events
      • Game - The in-game time of day becomes Equal to 0.00
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Daysoftheweek Less than 7
        • Then - Actions
          • Set Daysoftheweek = (Daysoftheweek + 1)
        • Else - Actions
          • Set Daysoftheweek = 1
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Daysoftheweek Equal to 1
        • Then - Actions
          • Game - Display to (All players) the text: Monday
        • Else - Actions
          • Do nothing
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Daysoftheweek Equal to 2
        • Then - Actions
          • Game - Display to (All players) the text: Tuesday
        • Else - Actions
          • Do nothing
  • And so on for all 7 days of the week
DaysoftheWeek is an Integer variable with initial value of 1.

By the way, I see you're using arrays in your variables. They're not neccesary or this trigger and if you don't know how to use them, I'd suggest to read some tutorials or don't use them at all :)
 
Level 11
Joined
Jun 13, 2007
Messages
570
i'm pretty certain the the game time never hits 24, it hits 23.99 then goes to 00.00

which could be throwing everything off
 
Status
Not open for further replies.
Top