Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help Switch (Case/Break thingy)
Daemian Offline
Posting Freak

Posts: 1,129
Threads: 42
Joined: Dec 2012
Reputation: 49
#3
RE: Switch (Case/Break thingy)

Inside your function timer_wakeup you have a name of a variable wrong:
The counter++ AddLocalVarInt("var_wakup", 1);
And the check at the bottom if (GetLocalVarInt("var_wakeup") <9)



Since var_wakeup it's gonna return 0, the timer is gonna get called every time.
Additionally, since the switch function above failed to find any match after case 9, the variable SectionSpeed remains with 0.0f, as it was initially declared, creating an infinite timer.

And when your computer can't handle it, it crashes.

(This post was last modified: 09-25-2013, 12:01 PM by Daemian.)
09-25-2013, 12:00 PM
Find


Messages In This Thread
Switch (Case/Break thingy) - by CarnivorousJelly - 09-25-2013, 07:55 AM
RE: Switch (Case/Break thingy) - by Daemian - 09-25-2013, 12:00 PM
RE: Switch (Case/Break thingy) - by Kreekakon - 09-25-2013, 06:48 PM



Users browsing this thread: 1 Guest(s)