ERRO Pawn -
LokolowS - 02.12.2011
Me ajudem a ver o qq й de errado no GM BAC do Thiago_StreeT
ERRO:
Код:
C:\Documents and Settings\Lucas\Desktop\GameModes By Luks_Killer\gamemodes\BAC.pwn(48486) : warning 217: loose indentation
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
LINHA:
Код:
48482 SendClientMessage(playerid, COLOR_RED, "Nъmero Invбlido.");
48483 return 1;
48484 }
48485 }
48486 return 1;
48487 }
Re: ERRO Pawn -
steki. - 02.12.2011
No topo do GM: #pragma tabsize 0
Re: ERRO Pawn -
dPlaYer_ - 02.12.2011
ou entao й so apagar os espaзos dessas linhas ai '-'
Re: ERRO Pawn -
LokolowS - 02.12.2011
mas o erro esta naquele return 1 ali e nao sei como resolver!
Re: ERRO Pawn -
ViniBorn - 02.12.2011
Posta o comando/funзгo completo(a)
Re: ERRO Pawn -
LokolowS - 02.12.2011
Код:
if(strcmp(cmd, "/porbomba", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREEN, "USE: /porbomba [ID DA VITIMA]");
return 1;
}
new vitima;
new vitimac;
vitima = ReturnUser(tmp);
if(vitima != INVALID_PLAYER_ID)
{
if(playerid == vitima){SendClientMessage(playerid, COLOR_RED, "Nгo pode usar este comando em vocк mesmo!"); return 1;}
vitimac = gLastCar[vitima];
matador = playerid;
if(PlayerInfo[playerid][pMembro] == 8 || PlayerInfo[playerid][pLider] == 8) // verificar se no seu gm hitmam eh esse valor e se nгo й pMember ou pLeader ou outra coisa
{
if (PlayerInfo[playerid][pCargo] >= 3)
{
if (carrobb1 == 0)
{
new usando = 1;
new Float:vX,Float:vY,Float:vZ;
GetVehiclePos(vitimac,vX,vY,vZ);
if(PlayerToPoint(3.5,playerid,vX,vY,vZ))
{
if (ProxDetectorS(5.0, playerid, vitima))
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
new ncar;
ncar = GetPlayerVehicleID(i);
if(!IsPlayerInVehicle(i, ncar))
{
usando = 0;
}
else
{
SendClientMessage(matador, COLOR_RED, "A bomba nгo pode ser plantada com a pessoa no carro");
return 1;
}
}
if(usando == 0)
{
vitimacarro = vitimac;
carrobb1 = 1;
SetTimer("tempocarrobb1", 120000, 0); // 000 = milйsimos entгo 1000 = 1 segundo, logo 300000 = 5 minutos
usando = 1;
SendClientMessage(playerid,0xFFFF00AA,"Bomba plantada.");
return 1;
}
else
{
SendClientMessage(matador, COLOR_RED, "A bomba nгo pode ser plantada com a pessoa no carro");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "A vнtima estб muito prуxima б vocк.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Vocк nгo estб perto do carro da vнtima.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Aguйm usou este comando, aguarde alguns minutos.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Deve ser cargo 3+");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Vocк nгo й Hitman, para usar este comando.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Nъmero Invбlido.");
return 1;
}
}
return 1;
}
Re: ERRO Pawn -
|_MeGaTroN_| - 02.12.2011
pawn Код:
if(strcmp(cmd, "/porbomba", true) == 0)
{
if(IsPlayerConnected(playerid)) {
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, COLOR_GREEN, "USE: /porbomba [ID DA VITIMA]");
return 1;
}
new vitima;
new vitimac;
vitima = ReturnUser(tmp);
if(vitima != INVALID_PLAYER_ID) {
if(playerid == vitima){SendClientMessage(playerid, COLOR_RED, "Nгo pode usar este comando em vocк mesmo!"); return 1;}
vitimac = gLastCar[vitima];
matador = playerid;
// verificar se no seu gm hitmam eh esse valor e se nгo й pMember ou pLeader ou outra coisa
if(PlayerInfo[playerid][pMembro] == 8 || PlayerInfo[playerid][pLider] == 8) {
if (PlayerInfo[playerid][pCargo] >= 3) {
if (carrobb1 == 0) {
new usando = 1;
new Float:vX,Float:vY,Float:vZ;
GetVehiclePos(vitimac,vX,vY,vZ);
if(PlayerToPoint(3.5,playerid,vX,vY,vZ)) {
if (ProxDetectorS(5.0, playerid, vitima)) {
for(new i = 0; i < MAX_PLAYERS; i++) {
new ncar;
ncar = GetPlayerVehicleID(i);
if(!IsPlayerInVehicle(i, ncar)) {
usando = 0;
}
else {
SendClientMessage(matador, COLOR_RED, "A bomba nгo pode ser plantada com a pessoa no carro");
return 1;
}
}
if(usando == 0) {
vitimacarro = vitimac;
carrobb1 = 1;
// 000 = milйsimos entгo 1000 = 1 segundo, logo 300000 = 5 minutos
SetTimer("tempocarrobb1", 120000, 0);
usando = 1;
SendClientMessage(playerid,0xFFFF00AA,"Bomba plantada.");
return 1;
}
else {
SendClientMessage(matador, COLOR_RED, "A bomba nгo pode ser plantada com a pessoa no carro");
return 1;
}
}
else {
SendClientMessage(playerid, COLOR_RED, "A vнtima estб muito prуxima б vocк.");
return 1;
}
}
else {
SendClientMessage(playerid, COLOR_RED, "Vocк nгo estб perto do carro da vнtima.");
return 1;
}
}
else {
SendClientMessage(playerid, COLOR_RED, "Aguйm usou este comando, aguarde alguns minutos.");
return 1;
}
}
else {
SendClientMessage(playerid, COLOR_RED, "Deve ser cargo 3+");
return 1;
}
}
else {
SendClientMessage(playerid, COLOR_RED, "Vocк nгo й Hitman, para usar este comando.");
return 1;
}
}
else {
SendClientMessage(playerid, COLOR_RED, "Nъmero Invбlido.");
return 1;
}
}
return 1;
}
Re: ERRO Pawn -
ViniBorn - 02.12.2011
pawn Код:
if(strcmp(cmd, "/porbomba", true) == 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
return SendClientMessage(playerid, COLOR_GREEN, "USE: /porbomba [ID DA VITIMA]");
new vitima,vitimac;
vitima = ReturnUser(tmp);
if(vitima != INVALID_PLAYER_ID)
{
if(playerid == vitima)
return SendClientMessage(playerid, COLOR_RED, "Nгo pode usar este comando em vocк mesmo!");
vitimac = gLastCar[vitima];
matador = playerid;
if(PlayerInfo[playerid][pMembro] == 8 || PlayerInfo[playerid][pLider] == 8) // verificar se no seu gm hitmam eh esse valor e se nгo й pMember ou pLeader ou outra coisa
{
if (PlayerInfo[playerid][pCargo] >= 3)
{
if (carrobb1 == 0)
{
new usando = 1;
new Float:vX,Float:vY,Float:vZ;
GetVehiclePos(vitimac,vX,vY,vZ);
if(PlayerToPoint(3.5,playerid,vX,vY,vZ))
{
if(ProxDetectorS(5.0, playerid, vitima))
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
new ncar;
ncar = GetPlayerVehicleID(i);
if(!IsPlayerInVehicle(i, ncar))
usando = 0;
else
SendClientMessage(matador, COLOR_RED, "A bomba nгo pode ser plantada com a pessoa no carro");
}
if(usando == 0)
{
vitimacarro = vitimac;
carrobb1 = 1;
SetTimer("tempocarrobb1", 120000, 0); // 000 = milйsimos entгo 1000 = 1 segundo, logo 300000 = 5 minutos
usando = 1;
SendClientMessage(playerid,0xFFFF00AA,"Bomba plantada.");
return 1;
}
else
return SendClientMessage(matador, COLOR_RED, "A bomba nгo pode ser plantada com a pessoa no carro");
}
else
return SendClientMessage(playerid, COLOR_RED, "A vнtima estб muito prуxima б vocк.");
}
else
return SendClientMessage(playerid, COLOR_RED, "Vocк nгo estб perto do carro da vнtima.");
}
else
return SendClientMessage(playerid, COLOR_RED, "Aguйm usou este comando, aguarde alguns minutos.");
}
else
return SendClientMessage(playerid, COLOR_RED, "Deve ser cargo 3+");
}
else
return SendClientMessage(playerid, COLOR_RED, "Vocк nгo й Hitman, para usar este comando.");
}
else
return SendClientMessage(playerid, COLOR_RED, "Nъmero Invбlido.");
return 1;
}