Which is better Per Player Timer or Global timer? (issue with timer)
#1

Several and randomly timers stop working in samp.

I use 1 global timer for all players using foreach however it seems that it suddenly stops working and won't run every minute.
It updates variables like
Jail time etc.

I've been having a lot of issues with timers including inaccuracies and I have to restart the server just to fix.

I have killed all timers ongamemodeexit

I don't think using per player timers is exactly efficient? I mean say I had 500 players online (not likely just saying) wouldn't that cause serious issue?

Thanks,
Grant
Reply
#2

Yes, use y_timers or try to use gettime instead of timers anywhere you can, starting with that jail time
Reply
#3

global timer,

task dokinstimer[1000](){ return 1;}
Reply
#4

This has been discussed many, many times already and it was established that many timers with tiny bits of fast code would be better than one large timer with slow code. Timers are also roughly 20% too fast. If you want a true 1 second timer you should actually use something like 850 ms instead.
Reply
#5

I see but would this cause my timers to mess up and ultimately stop working? My timer is actually about 25% slow but the other is accurate. When I use timer fix it appears not to work and a random timer stops I'm completely lost.

The code under the one minute timer is pretty big wouldn't this cause a lot of issues if I did per player?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)