C:\Users\JustinS\Desktop\LDL.pwn(9683) : warning 219: local variable "tmp" shadows a variable at a preceding level
C:\Users\JustinS\Desktop\LDL.pwn(9697) : error 001: expected token: ")", but found ";"
C:\Users\JustinS\Desktop\LDL.pwn(9697) : error 036: empty statement
C:\Users\JustinS\Desktop\LDL.pwn(9712) : error 029: invalid expression, assumed zero
die zeile
if(strcmp(cmd, "/befrei", true) == 0)
{
new tmp[256];
new giveplayer[200];
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
new otherplayer = strval(tmp);
new sendername[MAX_PLAYER_NAME];
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_WHITE, "[BENUTZUNG]: /befrei [SpielerID]");
return 1;
}
if(!IsPlayerConnected(otherplayer)) return SendClientMessage(playerid, COLOR_WHITE, "Falsche SpielerID !");
if(GetDistanceBetweenPlayers(playerid,otherplayer <= 5.0);
{
GetPlayerName(otherplayer, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
new Float:X;
new Float:Y;
new Float:Z;
new string[256];
GetPlayerPos(playerid,X,Y,Z);
SetPlayerPos(otherplayer,X,Y+1,Z);
format(string, sizeof(string), "Du hast %s gerettet!!.", giveplayer);
SendClientMessage(playerid,COLOR_WHITE, string);
SendClientMessage(otherplayer, COLOR_WHITE, "Du wurdest gerettet");
TogglePlayerControllable(playerid, 1);
}
else
{
SendClientMessage(playerid, COLOR_RED, "Der Spieler ist zu weit von dir entfernt !");
}
}
return 1;
}