03.07.2009, 12:41
Hi there
i have this command and i want that players can use this command only once in 2 minutes.
Can help ?
if(strcmp(cmdtext, "/naudoti", true)==0)
{
if(playerDB[playerid][narkotikai]<1)
{
SendClientMessage(playerid, COLOR, "* Neturite narkotiku");
return 1;
}
ApplyAnimation(playerid,"PED","WALK_DRUNK",4.1,1,1 ,1,1,1);
playerDB[playerid][narkotikai]-=1;
SetPlayerHealth(playerid,100);
SendClientMessage(playerid,COLOR,"* Naudojate narkotikus");
SetPlayerScore(playerid,GetPlayerScore(playerid)-5);
return 1;
}
i have this command and i want that players can use this command only once in 2 minutes.
Can help ?
if(strcmp(cmdtext, "/naudoti", true)==0)
{
if(playerDB[playerid][narkotikai]<1)
{
SendClientMessage(playerid, COLOR, "* Neturite narkotiku");
return 1;
}
ApplyAnimation(playerid,"PED","WALK_DRUNK",4.1,1,1 ,1,1,1);
playerDB[playerid][narkotikai]-=1;
SetPlayerHealth(playerid,100);
SendClientMessage(playerid,COLOR,"* Naudojate narkotikus");
SetPlayerScore(playerid,GetPlayerScore(playerid)-5);
return 1;
}