cartoys.pwn(96) : warning 217: loose indentation
DestroyVehicleToys(carid, delete = 0) {
for(new i=0;i<MAX_CAR_TOYS_PER_CAR;i++) {
if(VehicleCarToys[carid][i][EVehCarToy_ObjID] != 0)
DestroyCarToy(VehicleCarToys[carid][i][EVehCarToy_ObjID], delete);
VehicleCarToys[carid][i][EVehCarToy_SQLID] = 0;
}
}
I got one warning can anyone help?
Код:
cartoys.pwn(96) : warning 217: loose indentation pawn Код:
|
DestroyVehicleToys(carid, delete = 0) {
for(new i=0;i<MAX_CAR_TOYS_PER_CAR;i++) {
if(VehicleCarToys[carid][i][EVehCarToy_ObjID] != 0) {
DestroyCarToy(VehicleCarToys[carid][i][EVehCarToy_ObjID], delete);
VehicleCarToys[carid][i][EVehCarToy_SQLID] = 0;
}
}
}
\account.pwn(1497) : error 017: undefined symbol "playerid" \account.pwn(1498) : error 017: undefined symbol "playerid"
buylevel()
{
foreach(Player, i)
{
new nxtlevel = GetPVarInt(i, "Level")+1;
//new costlevel = nxtlevel*levelcost;
new expamount = nxtlevel*levelexp;
new infostring[96];
new exp = GetPVarInt(i, "RespectPoints");
if (exp < expamount)
{
format(infostring, sizeof(infostring), " You need %d respect points! You only have [%d] !",expamount,GetPVarInt(playerid,"RespectPoints"));
SendClientMessage(playerid, COLOR_LIGHTRED, infostring);
continue;
}
format(infostring, sizeof(infostring), "~g~LEVEL UP~n~~w~You Are Now Level %d", nxtlevel);
GameTextForPlayer(i, infostring, 5000, 1);
PlayerPlaySound(i, 1052, 0.0, 0.0, 0.0);
PlayerPlayMusic(i);
//GiveMoneyEx(playerid, -costlevel);
SetPVarInt(i, "Level", nxtlevel);
SetPlayerScore(i, nxtlevel);
exp -= expamount;
SetPVarInt(i, "RespectPoints", exp);
}
}
You mean where is (playerid, ...............) I have to do it (i, .....................)
![]() |
buylevel()
{
foreach(Player, i)
{
new nxtlevel = GetPVarInt(i, "Level")+1;
//new costlevel = nxtlevel*levelcost;
new expamount = nxtlevel*levelexp;
new infostring[96];
new exp = GetPVarInt(i, "RespectPoints");
if (exp < expamount)
{
format(infostring, sizeof(infostring), " You need %d respect points! You only have [%d] !",expamount,GetPVarInt(i,"RespectPoints"));
SendClientMessage(i, COLOR_LIGHTRED, infostring);
continue;
}
format(infostring, sizeof(infostring), "~g~LEVEL UP~n~~w~You Are Now Level %d", nxtlevel);
GameTextForPlayer(i, infostring, 5000, 1);
PlayerPlaySound(i, 1052, 0.0, 0.0, 0.0);
PlayerPlayMusic(i);
//GiveMoneyEx(playerid, -costlevel);
SetPVarInt(i, "Level", nxtlevel);
SetPlayerScore(i, nxtlevel);
exp -= expamount;
SetPVarInt(i, "RespectPoints", exp);
}
}