Uno me paso este codigo:
pawn Код:
if(strcmp(cmd,"/ddcount",true) == 0 || strcmp(cmd,"/ddcd",true) == 0) // By CuervO_NegrO
{
if(PlayerInfo[playerid][pDM] == 1)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /ddcout [seconds(3-60)]");
return 1;
}
new countdowns = strval(tmp);
if((countdowns > 60 || countdowns < 3)) return SendClientMessage(playerid, COLOR_GREY,"* Seconds must not go above 60 or below 3!");
ddcount = countdowns;
ddcounttimer = SetTimer("DDCountdown", 1000, true);
}
return 1;
}
PERO errror:
C:\Users\user\Desktop\****\gamemodes\larp.pwn(5681 9) : warning 217: loose indentation
C:\Users\user\Desktop\****\gamemodes\larp.pwn(5683

: warning 217: loose indentation
C:\Users\user\Desktop\****\gamemodes\larp.pwn(7884

: warning 219: local variable "ddcount" shadows a variable at a preceding level
C:\Users\user\Desktop\****\gamemodes\larp.pwn(7887 0) : error 054: unmatched closing brace ("}")
C:\Users\user\Desktop\****\gamemodes\larp.pwn(5683 1) : warning 204: symbol is assigned a value that is never used: "ddcount"
C:\Users\user\Desktop\****\gamemodes\larp.pwn(5683 2) : warning 204: symbol is assigned a value that is never used: "ddcounttimer"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
1 Error.
Yo no se si tendrй que borrar el public ddcountdown :S