[Tutorial] Stats in textdraws
#4

"SetTimerEx("CheckPlayerStatsKeys", 200, 1, "d", playerid);"

What's wrong with OnPlayerKeyStateChange?

pawn Code:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    if(newkeys & KEY_FIRE) return CloseStatsBox(playerid);
    return 1;
}
Think more effectively rather than a 200 Millisecond timer..

Using one include for something rather small is frankly quite pointless.
Doing this will make a 8 bit array without any includes.

I present, the char array!

pawn Code:
new
    bool: isstatsShowed [ MAX_PLAYERS char ]
;
#define StatsShowed(%1) (isStatsShowed{(%1)}=true)
if(StatsShowed(playerid)) return HideStats(playerid);
So on..
Reply


Messages In This Thread
Stats in textdraws - by System64 - 05.10.2011, 15:14
Re: Stats in textdraws - by Nenad - 05.10.2011, 20:37
Re: Stats in textdraws - by grand.Theft.Otto - 05.10.2011, 23:11
Re: Stats in textdraws - by Lorenc_ - 06.10.2011, 02:42
Re: Stats in textdraws - by System64 - 06.10.2011, 06:48
Re: Stats in textdraws - by Biesmen - 06.10.2011, 09:16
Re: Stats in textdraws - by aRoach - 06.10.2011, 09:22
Re: Stats in textdraws - by System64 - 06.10.2011, 09:31
Re: Stats in textdraws - by sonn51280 - 04.09.2018, 14:01
Re: Stats in textdraws - by solstice_ - 04.09.2018, 14:02

Forum Jump:


Users browsing this thread: 1 Guest(s)