Skip to content

Simple Question: State Trigger

CallirgosCallirgos Member Posts: 105
Would someone know what happens if you have a state trigger check a global variable that hasn't been set yet?
Would it default to true or false? Or would something terrible happen?

For example. If I want to have a state (rumor) happen only if
!GlobalTimerExpired("Samuel","GLOBAL")

And that global hasn't been set yet. What would happen?

Comments

  • jasteyjastey Member Posts: 2,669
    That trigger should only give true as long as the timer ("Samuel","GLOBAL") has not run out, i.e. after it was set until it runs out. Using the trigger before the timer was even set would just be treated as a false trigger, so nothing would happen (this rumor would not show).
    A variable that hasn't been set yet would give true if checked for a value of "0", checking for any other value just makes it a false trigger (becaue it wasn't set).

    If you have modding questions you might consider asking in the Modding Q&A at G3, there are more modders around there.
  • CallirgosCallirgos Member Posts: 105
    Thank you for the reply.

    Could I use a condition like this then?
    GlobalLT("Samuel","GLOBAL",1)

    I'm currently in a country that has many websites blocked... G3 included. Though they are great, as is Spellhold Studios.

    Would someone be able to send me the latest WIEDU and NEAR INFINITY. I can't get on GitHub.

Sign In or Register to comment.