SA-MP Forums Archive
[HELP]GivePlayerWeapon - 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: [HELP]GivePlayerWeapon (/showthread.php?tid=119951)



[HELP]GivePlayerWeapon - deather - 10.01.2010

I use a dialog box for ammunation.

Код:
if(listitem == 0)
	  {
	  GivePlayerWeapon(playerid,346,500);
	  GivePlayerMoney(playerid, -500);
	  }
This is the code i use for each weapon. But when i click the option it give -500 dollars but not weapons. For any weapon id it doesnt work. Help me.


Re: [HELP]GivePlayerWeapon - DiddyBop - 10.01.2010

"GivePlayerWeapon(playerid,346,500);"

LOL?

Should be

pawn Код:
GivePlayerWeapon(playerid,46,500);//Parachute



Re: [HELP]GivePlayerWeapon - Grim_ - 10.01.2010

You are giving invalid weapon IDs. I believe you are putting the model instead of the id.

Please check here for a list of all of the IDs (the far left column).
https://sampwiki.blast.hk/wiki/Weapons

For example, an M4 = 31 not 356.


Re: [HELP]GivePlayerWeapon - deather - 10.01.2010

Thank you. I gave the Model number instead of ID.
thank you very much
Please help me at this topic
http://forum.sa-mp.com/index.php?top...0179#msg870179


Re: [HELP]GivePlayerWeapon - Fedee! - 10.01.2010

Quote:
Originally Posted by deather
Thank you. I gave the Model number instead of ID.
thank you very much
Please help me at this topic
http://forum.sa-mp.com/index.php?top...0179#msg870179
It happend me the same sometime ago