Is this possible - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Is this possible (
/showthread.php?tid=143533)
Is this possible -
sjvt - 23.04.2010
If a cop stun the player and jail him, and the player do /payjailfine, he lose then 1000$ how can i make it that the server give the cop 1000$ (the cop that jail that player)
Re: Is this possible -
shady91 - 23.04.2010
just make a variable so like it would be
pawn Код:
//on your jail cmd add
SetPVarInt(suspectid, "WhoArrestedMe", playerid);
// then to your pay fine cmd
GivePlayerMoney(playerid, -1000);
GivePlayerMoney(GetPVarInt(playerid, "WhoArrestedMe"), 1000);
//that will give that cop who arrested him $1000 that the suspect pays
Re: Is this possible -
sjvt - 23.04.2010
Quote:
|
Originally Posted by Shady91
just make a variable so like it would be
pawn Код:
//on your jail cmd add
SetPVarInt(suspectid, "WhoArrestedMe", playerid);
// then to your pay fine cmd
GivePlayerMoney(playerid, -1000); GivePlayerMoney(GetPVarInt(playerid, "WhoArrestedMe"), 1000);// that will give that cop who arrested him $1000 that the suspect pays
|
Ok thx :P sorry im not really good
Re: Is this possible -
shady91 - 23.04.2010
Quote:
|
Originally Posted by Silox
Quote:
|
Originally Posted by Shady91
just make a variable so like it would be
pawn Код:
//on your jail cmd add
SetPVarInt(suspectid, "WhoArrestedMe", playerid);
// then to your pay fine cmd
GivePlayerMoney(playerid, -1000); GivePlayerMoney(GetPVarInt(playerid, "WhoArrestedMe"), 1000);// that will give that cop who arrested him $1000 that the suspect pays
|
Ok thx :P sorry im a beginner
|
No problem post your jail and pay fine command here and I'll add it for you if you don't know how to.
Re: Is this possible -
sjvt - 23.04.2010
pawn Код:
C:\Documents and Settings\Gebruiker\Bureaublad\GTACity\gamemodes\script.pwn(5970) : error 035: argument type mismatch (argument 1)
pawn Код:
SetPVarInt(PlayerSuspect, "WhoArrestedMe", playerid);
Re: Is this possible -
CAR - 23.04.2010
pawn Код:
SetPVarInt(PlayerSuspect, "WhoArrestedMe", playerid);
if your command is like /jail [id] then the id is called here "PlayerSuspect" you must change this to your id