Nem gondolod, hogy egy kicsit hosszú a dialogús?
D:\\GTA modok\\Mod\\mod\\Moddddd\\Mod\\régi\\régi\\filterscripts\\index.pwn(99) : warning 204: symbol is assigned a value that is never used: \"lights\" D:\\GTA modok\\Mod\\mod\\Moddddd\\Mod\\régi\\régi\\filterscripts\\index.pwn(132) : warning 204: symbol is assigned a value that is never used: \"lights\" D:\\GTA modok\\Mod\\mod\\Moddddd\\Mod\\régi\\régi\\filterscripts\\index.pwn(166) : warning 217: loose indentation D:\\GTA modok\\Mod\\mod\\Moddddd\\Mod\\régi\\régi\\filterscripts\\index.pwn(270) : warning 217: loose indentation Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase 4 Warnings.
#include <a_samp> #define BLINK_RATE 400 #define PFLASH_RATE 300 #define LIGHT_KEY KEY_SUBMISSION #undef MAX_PLAYERS #define MAX_PLAYERS 50 #define PRESSED(%0) \\ (((newkeys & (%0)) == (%0)) && ((oldkeys & (%0)) != (%0))) new BlinkTime[MAX_PLAYERS]; public OnPlayerDisconnect(playerid, reason) { KillTimer(BlinkTime[playerid]); return 1; } public OnPlayerStateChange(playerid, newstate, oldstate) { if(newstate == PLAYER_STATE_DRIVER) { new panels, doors, lights, tires; new carid = GetPlayerVehicleID(playerid); GetVehicleDamageStatus(carid, panels, doors, lights, tires); lights = encode_lights(1, 1, 1, 1); SetPVarInt(playerid, \"vMainOn\", 0); UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); } else if(newstate == PLAYER_STATE_ONFOOT) { KillTimer(BlinkTime[playerid]); SetPVarInt(playerid, \"CopFlash\", 0); } return 1; } public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) { if(PRESSED(LIGHT_KEY)) { if(IsPlayerInAnyVehicle(playerid) && GetPlayerVehicleSeat(playerid) == 0) { if(GetPVarInt(playerid, \"CopFlash\") == 0) { new panels, doors, lights, tires; new carid = GetPlayerVehicleID(playerid); GetVehicleDamageStatus(carid, panels, doors, lights, tires); switch(GetPVarInt(playerid, \"vMainOn\")) { case 0:{ lights = encode_lights(0, 0, 0, 0); SetPVarInt(playerid, \"vMainOn\", 1); } case 1:{ lights = encode_lights(1, 1, 1, 1); SetPVarInt(playerid, \"vMainOn\", 0); } } UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); } } } if(PRESSED(KEY_CROUCH)) { if(IsPublicService(GetPlayerVehicleID(playerid)) && GetPlayerVehicleSeat(playerid) == 0) { switch(GetPVarInt(playerid, \"CopFlash\")) { case 0:{ KillTimer(BlinkTime[playerid]); BlinkTime[playerid] = SetTimerEx(\"vBlinker\", PFLASH_RATE, 1, \"i\", playerid); SetPVarInt(playerid, \"CopFlash\", 1); } case 1:{ KillTimer(BlinkTime[playerid]); new panels, doors, lights, tires; new carid = GetPlayerVehicleID(playerid); GetVehicleDamageStatus(carid, panels, doors, lights, tires); lights = encode_lights(1, 1, 1, 1); UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); SetPVarInt(playerid, \"CopFlash\", 0); } } } } if(PRESSED(KEY_LOOK_LEFT)) { if(GetPlayerVehicleSeat(playerid) == 0) { if(GetPVarInt(playerid, \"vBLeft\") == 0) { new lights; KillTimer(BlinkTime[playerid]); BlinkTime[playerid] = SetTimerEx(\"vBlinker\", BLINK_RATE, 1, \"i\", playerid); lights = encode_lights(1, 1, 1, 1); SetPVarInt(playerid, \"vBLeft\", 1); SetPVarInt(playerid, \"vBRight\", 0); }else{ KillTimer(BlinkTime[playerid]); new panels, doors, lights, tires; new carid = GetPlayerVehicleID(playerid); GetVehicleDamageStatus(carid, panels, doors, lights, tires); switch(GetPVarInt(playerid, \"vMainOn\")){ case 0:{ lights = encode_lights(1, 1, 1, 1); } case 1:{ lights = encode_lights(0, 0, 0, 0); } } UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); lights = encode_lights(0, 0, 0, 0); SetPVarInt(playerid, \"vBLeft\", 0); } } } if(PRESSED(KEY_LOOK_RIGHT)) { if(GetPlayerVehicleSeat(playerid) == 0) { if(GetPVarInt(playerid, \"vBRight\") == 0) { new lights; KillTimer(BlinkTime[playerid]); BlinkTime[playerid] = SetTimerEx(\"vBlinker\", BLINK_RATE, 1, \"i\", playerid); SetPVarInt(playerid, \"vBRight\", 1); lights = encode_lights(1, 1, 1, 1); lights = encode_lights(0, 0, 0, 0); SetPVarInt(playerid, \"vBLeft\", 0); }else{ KillTimer(BlinkTime[playerid]); new panels, doors, lights, tires; new carid = GetPlayerVehicleID(playerid); GetVehicleDamageStatus(carid, panels, doors, lights, tires); switch(GetPVarInt(playerid, \"vMainOn\")){ case 0:{ lights = encode_lights(1, 1, 1, 1); } case 1:{ lights = encode_lights(0, 0, 0, 0); } } UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); lights = encode_lights(0, 0, 0, 0); SetPVarInt(playerid, \"vBRight\", 0); } } } return 1; } forward vBlinker(playerid); public vBlinker(playerid) { if(IsPlayerInAnyVehicle(playerid) && GetPVarInt(playerid, \"CopFlash\") != 1) { new Keys, ud, lr, panels, doors, lights, tires; new carid = GetPlayerVehicleID(playerid); GetPlayerKeys(playerid, Keys, ud, lr); GetVehicleDamageStatus(carid, panels, doors, lights, tires); if(lr > 0) { if(GetPVarInt(playerid, \"vBLeft\") == 1) { KillTimer(BlinkTime[playerid]); switch(GetPVarInt(playerid, \"vMainOn\")){ case 0:{ lights = encode_lights(1, 1, 1, 1); } case 1:{ lights = encode_lights(0, 0, 0, 0); } } UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); SetPVarInt(playerid, \"vBLeft\", 0); return 1; } } else if(lr < 0) { if(GetPVarInt(playerid, \"vBRight\") == 1) { KillTimer(BlinkTime[playerid]); switch(GetPVarInt(playerid, \"vMainOn\")){ case 0:{ lights = encode_lights(1, 1, 1, 1); } case 1:{ lights = encode_lights(0, 0, 0, 0); } } UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); SetPVarInt(playerid, \"vBRight\", 0); return 1; } } if(GetPVarInt(playerid, \"vBRight\") == 1) { switch(GetPVarInt(playerid, \"vMainOn\")){ case 0:{ switch(GetPVarInt(playerid, \"vBlinkOn\")){ case 0:{ lights = encode_lights(1, 1, 0, 0); SetPVarInt(playerid, \"vBlinkOn\", 1); } case 1:{ lights = encode_lights(1, 1, 1, 1); SetPVarInt(playerid, \"vBlinkOn\", 0); } } } case 1:{ switch(GetPVarInt(playerid, \"vBlinkOn\")){ case 0:{ lights = encode_lights(0, 0, 1, 1); SetPVarInt(playerid, \"vBlinkOn\", 1); } case 1:{ lights = encode_lights(0, 0, 0, 0); SetPVarInt(playerid, \"vBlinkOn\", 0); } } } } } if(GetPVarInt(playerid, \"vBLeft\") == 1) { switch(GetPVarInt(playerid, \"vMainOn\")){ case 0:{ switch(GetPVarInt(playerid, \"vBlinkOn\")){ case 0:{ lights = encode_lights(0, 0, 1, 1); SetPVarInt(playerid, \"vBlinkOn\", 1); } case 1:{ lights = encode_lights(1, 1, 1, 1); SetPVarInt(playerid, \"vBlinkOn\", 0); } } } case 1:{ switch(GetPVarInt(playerid, \"vBlinkOn\")){ case 0:{ lights = encode_lights(1, 1, 0, 0); SetPVarInt(playerid, \"vBlinkOn\", 1); } case 1:{ lights = encode_lights(0, 0, 0, 0); SetPVarInt(playerid, \"vBlinkOn\", 0); } } } } } UpdateVehicleDamageStatus(carid, panels, doors, lights, tires); } else if(GetPVarInt(playerid, \"CopFlash\") == 1) { new d[4]; new carid = GetPlayerVehicleID(playerid); GetVehicleDamageStatus(carid, d[0], d[1], d[2], d[3]); switch(GetPVarInt(playerid, \"vBlinkOn\")) { case 0:{ d[2] = encode_lights(1, 1, 0, 0); SetPVarInt(playerid, \"vBlinkOn\", 1); } case 1:{ d[2] = encode_lights(0, 0, 1, 1); SetPVarInt(playerid, \"vBlinkOn\", 0); } } UpdateVehicleDamageStatus(carid, d[0], d[1], d[2], d[3]); return 1; } return 1; } encode_lights(light1, light2, light3, light4) { return light1 | (light2 << 1) | (light3 << 2) | (light4 << 3); } IsPublicService(carid) { new PS[11] = { 416, 427, 490, 528, 407, 544, 596, 598, 597, 599, 601 }; for(new i = 0; i < sizeof(PS); i++) { if(GetVehicleModel(carid) == PS) return 1; } return 0; }
Strings without a length are deprecated, please add a destination size.
if(strcmp(cmdtext, \"/rob\", true) == 0{if(Lrabol[playerid]==false){ if(IsPlayerInRangeOfPoint(playerid,-270.0980,2716.1528,62.8077)) { Lrabol[playerid]=true; SetTimerEx(\"Lraboltimer\",90000,0,\"i\",playerid); TogglePlayerControllable(playerid,0); SetPlayerWantedLevel(playerid, GetPlayerWantedLevel(playerid) + 1); SendClientMessage(playerid, COLOR_LIGHTRED,\"Rabolod az egyes boltot!\"); format(string, sizeof(string), \"** RIADÓ: Los Santos-ban kirabolják az egyes boltot, siess! **\"); /*SendRadioMessage(1, COLOR_LIGHTRED, \"Rendõrségi rádió: Minden egységnek!! Las Payadasban a vegyesboltot kiraboljak!\"); SendRadioMessage(1, COLOR_LIGHTRED, \"Rendõrségi rádió: Az illetõnél fegyver van!Tûz parancs engedélyett 2.felszólítás után!\"); SendRadioMessage(1, COLOR_LIGHTRED, \"Rendõrségi rádió: Minden egységnek!! Las Payadasban a vegyesboltot kiraboljak!\");*/ } else SendClientMessage(playerid,COLOR_RED,\"Itt nem tudsz mit kireabolni!\");}else SendClientMessage(playerid,COLOR_RED,\"Most nem rabolhatsz!\");return 1;}[ }}
D:\\Bence\\CaliforniaStateRPG\\gamemodes\\cstaterp.pwn(8648) : error 010: invalid function or declarationD:\\Bence\\CaliforniaStateRPG\\gamemodes\\cstaterp.pwn(8649) : error 010: invalid function or declarationD:\\Bence\\CaliforniaStateRPG\\gamemodes\\cstaterp.pwn(8651) : error 010: invalid function or declarationD:\\Bence\\CaliforniaStateRPG\\gamemodes\\cstaterp.pwn(8653) : error 010: invalid function or declarationD:\\Bence\\CaliforniaStateRPG\\gamemodes\\cstaterp.pwn(8657) : error 010: invalid function or declarationD:\\Bence\\CaliforniaStateRPG\\gamemodes\\cstaterp.pwn(8662) : error 010: invalid function or declarationD:\\Bence\\CaliforniaStateRPG\\gamemodes\\cstaterp.pwn(8667) : error 010: invalid function or declaration
CMD:oltozo{if(IsPlayerConnected(playerid)){ if(pInfo[playerid][pFrakcio] == RFONOK || pInfo[playerid][pFrakcio] == RENDOR) { if(IsPlayerInRangeOfPoint(playerid, 5.0, 271.8459,118.8441,1004.6172)) { ShowPlayerDialog(playerid,DIALOG_STYLE_LIST,\"Szolgálati ruha - Rang szerint\",\"Commissioner\\nDeputy Commissioner\\nAssistant Commissioner\\nChief/A.Chief/Captain\\nLieutenant/Sergeant\\nOfficer\\nCadet\",\"Felveszem\",\"Mégse\"); } else { SendClientMessage(playerid,PIROS,\"Nem vagy az öltözõben!\"); }}else{ SendClientMessage(playerid,PIROS,\"Nem vagy a California State Police állományába tartozó személy!\");}}return 1;}
Talán a 22., és 23. sort kikellene törölni?
if(strcmp(cmdtext, \"/rob\", true) == 0{if(Lrabol[playerid]==false){ if(IsPlayerInRangeOfPoint(playerid,-270.0980,2716.1528,62.8077)) { Lrabol[playerid]=true; SetTimerEx(\"Lraboltimer\",90000,0,\"i\",playerid); TogglePlayerControllable(playerid,0); SetPlayerWantedLevel(playerid, GetPlayerWantedLevel(playerid) + 1); SendClientMessage(playerid, COLOR_LIGHTRED,\"Rabolod az egyes boltot!\"); format(string, sizeof(string), \"** RIADÓ: Los Santos-ban kirabolják az egyes boltot, siess! **\"); /*SendRadioMessage(1, COLOR_LIGHTRED, \"Rendõrségi rádió: Minden egységnek!! Las Payadasban a vegyesboltot kiraboljak!\"); SendRadioMessage(1, COLOR_LIGHTRED, \"Rendõrségi rádió: Az illetõnél fegyver van!Tûz parancs engedélyett 2.felszólítás után!\"); SendRadioMessage(1, COLOR_LIGHTRED, \"Rendõrségi rádió: Minden egységnek!! Las Payadasban a vegyesboltot kiraboljak!\");*/ } else SendClientMessage(playerid,COLOR_RED,\"Itt nem tudsz mit kireabolni!\");}else SendClientMessage(playerid,COLOR_RED,\"Most nem rabolhatsz!\");return 1;}
public OnPlayerEnterCheckpoint(playerid){ if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 515) if(uttisztito[playerid] == 1){ uttisztito[playerid] = 2; SetPlayerCheckpoint(playerid,777.9092,-1357.1815,13.5328,10); // 1. cp SendClientMessage(playerid,COLOR_YELLOW,\"* Kérlek menj bele minden piros körbe és megkapod a pénzed!\"); return 1; } if(uttisztito[playerid] == 1){ uttisztito[playerid] = 2; SetPlayerCheckpoint(playerid,482.9012,-1531.6816,19.5598,10); // 2. cp return 1; } if(uttisztito[playerid] == 2){ uttisztito[playerid] = 3; SetPlayerCheckpoint(playerid,-87.7171,-1124.9846,1.0853,10); return 1; } if(uttisztito[playerid] == 3){ uttisztito[playerid] = 4; SetPlayerCheckpoint(playerid,-1054.4229,-1174.1942,128.5683,10); return 1; } if(uttisztito[playerid] == 4){ uttisztito[playerid] = 5; SetPlayerCheckpoint(playerid,-2018.7128,78.4218,27.4641,10); return 1; } if(uttisztito[playerid] == 5){ uttisztito[playerid] = 6; SetPlayerCheckpoint(playerid,-1909.2917,834.8624,35.0156,10); return 1; } if(uttisztito[playerid] == 6){ uttisztito[playerid] = 0; SetPlayerCheckpoint(playerid,-1646.8132,1216.4912,7.1797,10); return 1; } { if(uttisztito[playerid] == 11){ uttisztito[playerid] = 0; DisablePlayerCheckpoint(playerid); SendClientMessage(playerid,COLOR_RED,\"Végeztél a munkával jutalom: {057CEA}Kaptál {33FF33}$3000\"); GivePlayerMoney(playerid,3000); return 1; }//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 574) if(PetrolJob[playerid] == 1){ PetrolJob[playerid] = 2; SetPlayerCheckpoint(playerid,777.9092,-1357.1815,13.5328,10); // 1. cp SendClientMessage(playerid,COLOR_YELLOW,\"* Kérlek menj bele minden piros körbe és megkapod a pénzed!\"); return 1; } if(PetrolJob[playerid] == 1){ PetrolJob[playerid] = 2; SetPlayerCheckpoint(playerid,482.9012,-1531.6816,19.5598,10); // 2. cp return 1; } if(PetrolJob[playerid] == 2){ PetrolJob[playerid] = 3; SetPlayerCheckpoint(playerid,-87.7171,-1124.9846,1.0853,10); return 1; } if(PetrolJob[playerid] == 3){ PetrolJob[playerid] = 4; SetPlayerCheckpoint(playerid,-1054.4229,-1174.1942,128.5683,10); return 1; } if(PetrolJob[playerid] == 4){ PetrolJob[playerid] = 5; SetPlayerCheckpoint(playerid,-2018.7128,78.4218,27.4641,10); return 1; } if(PetrolJob[playerid] == 5){ PetrolJob[playerid] = 6; SetPlayerCheckpoint(playerid,-1909.2917,834.8624,35.0156,10); return 1; } if(PetrolJob[playerid] == 6){ PetrolJob[playerid] = 0; SetPlayerCheckpoint(playerid,-1646.8132,1216.4912,7.1797,10); return 1; } { if(!IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid))){ SendClientMessage(playerid,COLOR_RED,\"* Kapcsolodj hozza egy pótkocsihoz!\"); DisablePlayerCheckpoint(playerid); return 1; } GivePlayerMoney(playerid,5000); SendClientMessage(playerid,COLOR_YELLOW,\"*Végeztél a munkával jutalom: {057CEA}Kaptál{33FF33}$5000-t!\"); DisablePlayerCheckpoint(playerid); }//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 448) { if(PizzaJob[playerid] == 1){ PizzaJob[playerid] = 2; SetPlayerCheckpoint(playerid,2011.4304,-1656.3767,13.5547,10); SendClientMessage(playerid,COLOR_YELLOW,\"* Kérlek menj bele minden piros körbe és megkapod a pénzed!\"); return 1; } if(PizzaJob[playerid] == 2){ PizzaJob[playerid] = 3; SetPlayerCheckpoint(playerid,2069.8394,-1600.4298,13.5314,10); return 1; } if(PizzaJob[playerid] == 3){ PizzaJob[playerid] = 4; SetPlayerCheckpoint(playerid,2238.0610,-1645.1483,15.4856,10); return 1; } if(PizzaJob[playerid] == 4){ PizzaJob[playerid] = 5; SetPlayerCheckpoint(playerid,2280.4871,-1651.3339,15.1891,10); return 1; } if(PizzaJob[playerid] == 5){ PizzaJob[playerid] = 6; SetPlayerCheckpoint(playerid,2306.4131,-1668.9806,14.5715,10); return 1; } if(PizzaJob[playerid] == 6){ PizzaJob[playerid] = 7; SetPlayerCheckpoint(playerid,2333.0281,-1680.2412,13.5796,10); return 1; } if(PizzaJob[playerid] == 7){ PizzaJob[playerid] = 8; SetPlayerCheckpoint(playerid,2390.0537,-1724.9608,13.5724,10); return 1; } if(PizzaJob[playerid] == { PizzaJob[playerid] = 9; SetPlayerCheckpoint(playerid,2421.2441,-1759.7205,13.5391,10); return 1; } if(PizzaJob[playerid] == 9){ PizzaJob[playerid] = 10; SetPlayerCheckpoint(playerid,2240.8374,-1886.9504,13.1486,10); return 1; } if(PizzaJob[playerid] == 10){ PizzaJob[playerid] = 11; SetPlayerCheckpoint(playerid,2095.5488,-1815.7517,12.9792,10); return 1; } if(PizzaJob[playerid] == 11){ PizzaJob[playerid] = 0; DisablePlayerCheckpoint(playerid); SendClientMessage(playerid,COLOR_RED,\"Végeztél a munkával jutalom: {057CEA}Kaptál {33FF33}$3000\"); GivePlayerMoney(playerid,3000); } } return 1;}