06.02.2010, 15:38
Код:
C:\Program Files\SAMP\gamemodes\erp.pwn(1551) : error 028: invalid subscript (not an array or too many subscripts): "Soidukid" C:\Program Files\SAMP\gamemodes\erp.pwn(1551) : warning 215: expression has no effect C:\Program Files\SAMP\gamemodes\erp.pwn(1551) : error 001: expected token: ";", but found "]" C:\Program Files\SAMP\gamemodes\erp.pwn(1551) : error 029: invalid expression, assumed zero C:\Program Files\SAMP\gamemodes\erp.pwn(1551) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
Код:
format(String, sizeof(String), "%s", List(GetVehicleModel(GetPlayerVehicleID(playerid))));
Код:
public OnPlayerStateChange(playerid, newstate, oldstate) { if(newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER) { new String[64]; format(String, sizeof(String), "%s", List(GetVehicleModel(GetPlayerVehicleID(playerid)))); TextDrawSetString(Soiduk, String); TextDrawShowForPlayer(playerid, Soiduk); format(String, sizeof(String), "%d KM/H", SaaSoidukiKiirus(playerid)); TextDrawSetString(KM, String); TextDrawShowForPlayer(playerid, KM); TextDrawShowForPlayer(playerid, Liiklusvahend); TextDrawShowForPlayer(playerid, Kiirus); } else if(oldstate == PLAYER_STATE_DRIVER || oldstate == PLAYER_STATE_PASSENGER) { TextDrawHideForPlayer(playerid, Kiirus); TextDrawHideForPlayer(playerid, KM); TextDrawHideForPlayer(playerid, Liiklusvahend); TextDrawHideForPlayer(playerid, Soiduk); } return 1; }