Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
timers
#1
i need help with timers, i tried doing it but ive never used em before and i have no idea how the work, how would you make it run code when the tiemr hits zero then reset?
Reply
#2
...

Why would the timer hit zero?

Unless you made that happen with code... which obviously isn't going to happen -.-;;
Quote:Robin:
Why aren't maps and shit loaded up in a dynamic array?
Jacob:
the 4 people that know how are lazy
Robin:
Who are those 4 people?
Jacob:
um
you, me, and 2 others?
Reply
#3
sorry man >.>, as i said in my post ive never used timers before and i havwe no idea how they work, i found some info on it, so they hit intervals ok, i have mine hitting 30000 milliseconds[30 secs] and then the SP should drop but it just doesnt do anything. my code is this

Code:
If GetPlayerSp(myindex) = 0 Then
        SetPlayerHp(MyIndex, GetPlayerHP(myindex) - 2)
Else
        SetPlayerSp(Myindex, GetplayerSP(myindex) -2)
End if
Reply
#4
Add some code for a message box in there and see if it comes up after 30 seconds.

If so, then your problem would be based on not sending the client the new HP and SP.

If not, then you forgot to enable the timer...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)