Question| How...???
#6

Ok look this is the problem i got it..

Код:
	if(strcmp(cmdtext, "/counter", true) == 0)
 {
 if(IsPlayerConnected(playerid))
 {
 	new tmpcar = GetPlayerVehicleID(playerid) - 1;
	if(PlayerInfo[playerid][pFaction] != 255 && DynamicFactions[PlayerInfo[playerid][pFaction]][fType] == 5)
	{
	if(!IsPlayerInAnyVehicle(playerid))
 	{
 	SendClientMessage(playerid, COLOR_VEH, " You are not in a car.");
	return 1;
 	}
	if(DynamicCars[tmpcar][FactionCar] != PlayerInfo[playerid][pFaction])
	{
	SendClientMessage(playerid, COLOR_VEH, " You are not in a faction vehicle.");
	return 1;
	}
	PlayerActionMessage(playerid,15.0,"turns on the counter.");
	SetTimer("countdown",500,0);
	}
	}
	else
	{
	SendClientMessage(playerid, COLOR_VEH, "Invalid Faction.");
	return 1;
	}}
and
Код:
forward countdown(playerid);
public countdown(playerid)
{
static loops = 10;
if (loops)
{
new cdtimer = SetTimer("countdown", 3000, 0);
#pragma unused cdtimer
new str[256];
format(str, sizeof (str), "~w~Counter: %d$", loops);
GameTextForPlayer(playerid,str,1000,4);
for(new i=0; i<MAX_PLAYERS; i++) {
if (IsPlayerConnected(i))
{
}
}
loops++;
}
else
{
for(new i=0; i<MAX_PLAYERS; i++) {
{
if (IsPlayerConnected(i))
{

}
}
loops = 10;
}
}
}
This is with Timer So how can i remove it by command ?? like /counter off
Reply


Messages In This Thread
Question| How...??? - by [Sk]Noob - 29.07.2009, 11:34
Re: Question| How...??? - by MachineHead - 29.07.2009, 11:35
Re: Question| How...??? - by [Sk]Noob - 29.07.2009, 11:37
Re: Question| How...??? - by pagie1111 - 29.07.2009, 11:44
Re: Question| How...??? - by Dj_maryo1993 - 29.07.2009, 11:51
Re: Question| How...??? - by [Sk]Noob - 29.07.2009, 12:02
Re: Question| How...??? - by pagie1111 - 29.07.2009, 12:05
Re: Question| How...??? - by [Sk]Noob - 29.07.2009, 12:28
Re: Question| How...??? - by [Sk]Noob - 29.07.2009, 12:32
Re: Question| How...??? - by D3nnis - 29.07.2009, 12:35

Forum Jump:


Users browsing this thread: 1 Guest(s)