[Ajuda] Drive-By - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: Non-English (
https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (
https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (
https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Drive-By (
/showthread.php?tid=338779)
[Ajuda] Drive-By -
Luciano* - 01.05.2012
Olб, achei esse codigo de "Anti Drive-By" aqui no forum, funciona certinho mais quando alguem morre com a explosao da bomba do hydra й kickado, alguem pode conserta-lo? e se nao for pedir muito, ser kickado ao matar com o "negуcio"(nao sei o nome correto) do helicуptero.
pawn Код:
if(IsPlayerInAnyVehicle(killerid))
{
if(GetVehicleModel(GetPlayerVehicleID(killerid)) != 425 || GetVehicleModel(GetPlayerVehicleID(killerid)) != 520)
{
SendClientMessage(playerid, "Voce cometeu DB e foi kickado");
Kick(killerid);
}
}
Re: [Ajuda] Drive-By -
.FuneraL. - 01.05.2012
pawn Код:
if(IsPlayerInAnyVehicle(killerid))
{
if(GetVehicleModel(GetPlayerVehicleID(killerid)) < 425 || GetVehicleModel(GetPlayerVehicleID(killerid)) > 520 || GetVehicleModel(GetPlayerVehicleID(killerid)) >= 426 || GetVehicleModel(GetPlayerVehicleID(killerid)) =< 519)
{
SendClientMessage(playerid, "Voce cometeu DB e foi kickado");
Kick(killerid);
}
}
Tente por isso ^^
Respuesta: [Ajuda] Drive-By -
Luciano* - 01.05.2012
pawn Код:
C:\Documents and Settings\Luciano\Desktop\GAMEMODE\gamemodes\LSTDM.pwn(937) : warning 211: possibly unintended assignment
C:\Documents and Settings\Luciano\Desktop\GAMEMODE\gamemodes\LSTDM.pwn(937) : error 022: must be lvalue (non-constant)
C:\Documents and Settings\Luciano\Desktop\GAMEMODE\gamemodes\LSTDM.pwn(937) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Luciano\Desktop\GAMEMODE\gamemodes\LSTDM.pwn(937) : warning 215: expression has no effect
C:\Documents and Settings\Luciano\Desktop\GAMEMODE\gamemodes\LSTDM.pwn(937) : error 001: expected token: ";", but found ")"
C:\Documents and Settings\Luciano\Desktop\GAMEMODE\gamemodes\LSTDM.pwn(937) : fatal error 107: too many error messages on one line
Linha:
pawn Код:
if(GetVehicleModel(GetPlayerVehicleID(killerid)) < 425 || GetVehicleModel(GetPlayerVehicleID(killerid)) > 520 || GetVehicleModel(GetPlayerVehicleID(killerid)) >= 426 || GetVehicleModel(GetPlayerVehicleID(killerid)) =< 519)
Re: [Ajuda] Drive-By -
Lucas_Alemao - 01.05.2012
Quote:
Originally Posted by .FuneraL.
pawn Код:
if(IsPlayerInAnyVehicle(killerid)) { if(GetVehicleModel(GetPlayerVehicleID(killerid)) < 425 || GetVehicleModel(GetPlayerVehicleID(killerid)) > 520 || GetVehicleModel(GetPlayerVehicleID(killerid)) >= 426 || GetVehicleModel(GetPlayerVehicleID(killerid)) =< 519) { SendClientMessage(playerid, "Voce cometeu DB e foi kickado"); Kick(killerid); } }
Tente por isso ^^
|
nem vo comentar....
Re: [Ajuda] Drive-By -
Caio_Freeze - 01.05.2012
Quote:
Originally Posted by Lucas_Alemao
nem vo comentar....
|
Vocк Jб Comento :P
Respuesta: [Ajuda] Drive-By -
Luciano* - 01.05.2012
Alguem que saiba conserta-lo?
Re: [Ajuda] Drive-By -
zbt - 01.05.2012
pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
if(IsPlayerInAnyVehicle(killerid))
{
switch(GetVehicleModel(GetPlayerVehicleID(killerid)))
{
case /*veiculos de guerra*/:
return false;
default: {
SendClientMessage(killerid, -1, "Voce cometeu DB e foi kickado");
Kick(killerid);
}
}
}
return true;
}
Pode ser usado reason tambй.
Respuesta: Re: [Ajuda] Drive-By -
Luciano* - 01.05.2012
Quote:
Originally Posted by zbt
pawn Код:
public OnPlayerDeath(playerid, killerid, reason) { if(IsPlayerInAnyVehicle(killerid)) { switch(GetVehicleModel(GetPlayerVehicleID(killerid))) { case /*veiculos de guerra*/: return false; default: { SendClientMessage(killerid, -1, "Voce cometeu DB e foi kickado"); Kick(killerid); } } } return true; }
Pode ser usado reason tambй.
|
Perfeito! +rep