16.11.2013, 17:48
PHP код:
CMD:fixmyvw(playerid, params[])
{
{
new rand = random(sizeof(RandomSpawn));
if(IsPlayerInRangeOfPoint(playerid, 10, -99.8344, 1106.8241, 19.2258))
GameTextForPlayer(playerid, "/fixmyvw to repair your car", 4000, 5);
SetPlayerPos(playerid, RandomSpawn[rand][0], RandomSpawn[rand][1],RandomSpawn[rand][2]);
SetPlayerFacingAngle(playerid, RandomSpawn[rand][3]);
if(IsPlayerInAnyVehicle(playerid) == 1)
{
new car = GetPlayerVehicleID(playerid);
SetVehiclePos(car, RandomSpawn[rand][0], RandomSpawn[rand][1],RandomSpawn[rand][2]);
PutPlayerInVehicle(playerid, car);
}
}
return 1;
}
new Float:RandomSpawn[][4] =
{
{-96.9210, 1118.1365, 19.2258, 0.0000},
{ -102.9209, 1118.1432, 19.2258, 0.0000},
{ -99.9409, 1118.1344, 19.2258, 0.0000}
};
Код:
C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(15565) : warning 202: number of arguments does not match definition C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(15807) : warning 202: number of arguments does not match definition C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(19292) : error 017: undefined symbol "RandomSpawn" C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(19292) : error 029: invalid expression, assumed zero C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(19292) : warning 215: expression has no effect C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(19295) : error 017: undefined symbol "RandomSpawn" C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(19296) : error 017: undefined symbol "RandomSpawn" C:\Users\Andrew\Desktop\samp server\gamemodes\RP.pwn(19300) : error 017: undefined symbol "RandomSpawn"