infinite ammo - 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)
+--- Thread: infinite ammo (
/showthread.php?tid=351047)
infinite ammo -
trulis - 14.06.2012
pawn Код:
if(strcmp(cmd, "/dgun", true) == 0)
{
if(IsPlayerConnected(playerid))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
if(PlayerInfo[playerid][pDonateRank] == 1)
{
format(string, sizeof(string), "*%s got an infinite ammo deagle.*", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 24, 999);
}
else
{
SendClientMessage(playerid, COLOR_GRAD2, " You are not a donator !");
return 1;
}
}
return 1;
}
I made this command and i want to know what do i need to replace the 999 with so i get infinite ammo when using this command.
Re: infinite ammo -
Vince - 14.06.2012
Replace with 0x7FFFFFFF.
Re: infinite ammo -
jessejanssen - 14.06.2012
You should change the 999 to 99999999999999999 or any number like that :P..
Jesse
Re: infinite ammo -
Face9000 - 14.06.2012
pawn Код:
GivePlayerWeapon(playerid, 24, 99999);
...?
Re: infinite ammo -
trulis - 14.06.2012
Thank you Vince, it worked.
Re: infinite ammo -
kaisersouse - 14.06.2012
Quote:
Originally Posted by Vince
Replace with 0x7FFFFFFF.
|
Using this. Thank you!!
Re: infinite ammo -
Phil_Cutcliffe - 13.02.2013
Quote:
Originally Posted by kaisersouse
Using this. Thank you!!
|
Haha using this too! I can't store any weapon in my vehicles because I set it to 999999 or something! Hopefully this will fix it for me! =D
Thankyou Vince!
Re: infinite ammo -
Ari - 14.02.2013
Quote:
Originally Posted by Vince
Replace with 0x7FFFFFFF.
|
Oooooh! defiantly going to use this in the future.
Using a define would be useful "#define AMMO 0x7FFFFFFF" "GivePlayerWeapon(playerid, 24, AMMO)"