24.09.2013, 21:42
(
Последний раз редактировалось =KempeR=; 24.09.2013 в 22:54.
)
Better realisation, without using timers
You can save commandShopUsed[playerid] to player's account
PHP код:
new commandShopUsed[MAX_PLAYERS];
#define commandShopInterval 3600 //in seconds
CMD:shop(playerid) {
if (gettime() < commandShopUsed[playerid])
return SendClientMessage(playerid, -1, "Please Wait to use this command again");
commandShopUsed[playerid] = gettime() + commandShopInterval;
//Common code starts here
return true;
}