06.03.2014, 12:48
Код:
CMD:reparar(playerid, params[]) { if(IsPlayerConnected(playerid)) { if(PlayerDados[playerid][pEmprego] !== Mecanico { SendClientMessage(playerid, -1, " Vocк nгo й mecanico!"); return 1; } tmp = strtok(cmdtext, idx); if(!strlen(tmp)) { SendClientMessage(playerid, -1, "USE: /reparar [id] [preco]"); return 1; } new playa; new money; playa = ReturnUser(tmp); tmp = strtok(cmdtext, idx); money = strval(tmp); if(money < 5 || money > 5000) { SendClientMessage(playerid, -1, " Preco minimo 5 <> preco maximo 5000!"); return 1; } if(IsPlayerConnected(playa)) { if(playa != INVALID_PLAYER_ID) { if(ProxDetectorS(8.0, playerid, playa)&& IsPlayerInAnyVehicle(playa)) { if(playa == playerid) { SendClientMessage(playerid, -1, " Nгo posso fazer isso!"); return 1; } GetPlayerName(playa, GivePlayer, sizeof(GivePlayer)); GetPlayerName(playerid, sendername, sizeof(sendername)); format(string, sizeof(string), "* Vocк ofereceu ao(a) %s para concertar seu carro por R$%d .",giveplayer,money); SendClientMessage(playerid, COLOR_LIGHTBLUE, string); format(string, sizeof(string), "* Mecanico %s quer reparar seu carro por R$%d, (Digite /aceitar reparo) para aceitar.",sendername,money); SendClientMessage(playa, COLOR_LIGHTBLUE, string); RepairOffer[playa] = playerid; RepairPrice[playa] = money; } else { SendClientMessage(playerid, -1, " Este jogador nao esta perto de Vocк ou nao esta no carro."); } } } else { SendClientMessage(playerid, COLOR_GREY, " O Jogador esta offline."); } } return 1; }
Код:
error 029: invalid expression, assumed zero error 029: invalid expression, assumed zero warning 225: unreachable code error 017: undefined symbol "tmp" error 017: undefined symbol "strtok" error 017: undefined symbol "tmp" error 017: undefined symbol "ReturnUser" error 017: undefined symbol "tmp" error 017: undefined symbol "strtok" error 017: undefined symbol "tmp" error 017: undefined symbol "ProxDetectorS" error 017: undefined symbol "GivePlayer" error 017: undefined symbol "GivePlayer" error 029: invalid expression, assumed zero fatal error 107: too many error messages on one line