(1913) : error 002: only a single statement (or expression) can follow each "case" ;/
#1

(1913) : error 002: only a single statement (or expression) can follow each "case"

The the 1913 line is bolded

Quote:

default:
{
SendClientMessage(playerid, Balta, "Invalid license type! /siren [type]");
SendClientMessage(playerid, Pilka, "Type: 1 = Roof, 2 = Inside, 3 = Off.");
}
else SendClientMessage(playerid, Balta, "You're not authorised to use this command.");
return 1;
}

forward ProxDetector(Float:radi, playerid, targetid);
public ProxDetector(Float:radi, playerid, targetid)
{
if(IsPlayerConnected(playerid)&&IsPlayerConnected( targetid))
{
new Float:posx, Float:posy, Float:posz;
new Float:oldposx, Float:oldposy, Float:oldposz;
new Float:tempposx, Float:tempposy, Float:tempposz;
GetPlayerPos(playerid, oldposx, oldposy, oldposz);
GetPlayerPos(targetid, posx, posy, posz);
tempposx = (oldposx -posx);
tempposy = (oldposy -posy);
tempposz = (oldposz -posz);
if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
{
return 1;
}
}
return 0;
}
Reply
#2

Uhhh, I had like 3 errors and I'm left with this one, isn't there a quick fix for it ? ;/
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)