[Ajuda] O que hб de errado? - 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] O que hб de errado? (
/showthread.php?tid=659590)
O que hб de errado? -
GuiLopez - 08.10.2018
Bom, recentemente eu fiz uma бrea de D.M no meu servidor, e gostaria que apenas nessa бrea ao atirar em um jogador fosse retornado um "bip"...
O cуdigo й esse abaixo:
Код:
public OnPlayerTakeDamage(playerid,issuerid,Float:amount,weaponid)
{
if(IsPlayerInPlace(playerid,2016.010986, -1161.922363, 2324.010986, -923.518310)){
PlayerPlaySound(issuerid,17802);
return 1;
}
}
Porйm apуs eu adicionar isso, e os jogadores trocarem tiros, o servidor desliga sozinho... O que hб de errado?
Server-Log:
Код:
[06:29:51] [kill] GuiLopez_ killed Guilherme Sawn-off Shotgun
[06:29:51] [debug] Run time error 6: "Invalid instruction"
[06:29:51] [debug] Unknown opcode 0x0 at address 0x0000FFFF
[06:29:51] [debug] AMX backtrace:
[06:29:51] [debug] Server crashed while executing gamemode.amx
[06:29:51] [debug] AMX backtrace:
[06:29:51] [debug] Server crashed while executing gamemode.amx
[06:29:51] [debug] AMX backtrace:
Re: O que hб de errado? -
Guscooby - 08.10.2018
Que versгo vocк usa?
Re: O que hб de errado? -
ipsLuan - 08.10.2018
Tente desta forma:
PHP код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid) {
if(IsPlayerInPlace(playerid, 2016.010986, -1161.922363, 2324.010986, -923.518310)) {
PlayerPlaySound(issuerid, 17802);
}
return 1;
}
Re: O que hб de errado? -
GuiLopez - 08.10.2018
Quote:
Originally Posted by ipsLuan
Tente desta forma:
PHP код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid) {
if(IsPlayerInPlace(playerid, 2016.010986, -1161.922363, 2324.010986, -923.518310)) {
PlayerPlaySound(issuerid, 17802);
}
return 1;
}
|
Continua desligando!
Re: O que hб de errado? -
ipsLuan - 08.10.2018
Faзa a substituiзгo para essa:
PHP код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid, bodypart) {
if(IsPlayerInPlace(playerid, 2016.010986, -1161.922363, 2324.010986, -923.518310)) {
PlayerPlaySound(issuerid, 17802, 0.0, 0.0, 0.0);
}
return 1;
}
Re: O que hб de errado? -
PT - 08.10.2018
falta um parametro
https://sampwiki.blast.hk/wiki/OnPlayerTakeDamage
OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid, bodypart)