[FilterScript] [FS/INC] WeaponDrop
#1

[FS/INC] WeaponDrop v1.1

Hello guys,
this is my fourth release. I had some free-time last week and made this little Filterscript, which can also be used as an Include. It will make your weapons drop on the floor as pickups when you die.

What is this Filterscript?
  • It is a little Filterscript, which drops your weapons as pickups when you die. You can also set, that a money-bag will be dropped with money in it. Later more.
Whats new in v1.1?
  • Added command: /dropweapon [opt:ammo]
  • Added OnWeaponDropExit();
Definitions:

#define WEAPON_RESPAWN_TIME
  • This is the time until the dropped pickups get destroyed. Modify it if you wish.
#define MONEY_BAG_MONEY
  • -1 = Money bad is ON and all money of the death player will be in it.
  • 0 = Money bag is OFF
  • 1+ = Money bag is ON with the defined number of money.
#define MONEY_BAG_MODE
  • 1 = Money comes from the death player.
  • 0 = Money comes from the server.
new ForbiddenWeapons[]= { 38, 44, 45 };
  • Here you enter the weapon IDs of the weapons you don't want to be created.
    I have already pre-defined three weapon IDs, but feel free to remove them if you wish.
Installation:
  • Filterscript version:
    • Download the script.
    • Place it as a new Filterscript in your 'filterscripts' folder.
    • Open your 'server.cfg' and write beside 'filterscripts': WeaponDrop
    • Save and run your server.
    • Enjoy!
  • Include verion:
    • Download the Include.
    • Place it as a new Include in your 'pawno/include' folder.
    • Open the FS/GM you want it to be in.
    • Now you have to add:
      • At OnGameModeInit or OnFilterScriptInit: OnWeaponDropInit();
      • At OnPlayerDeath: OnWeaponDrop(playerid)
      • At OnPlayerPickUpPickup: OnWeaponDropPickup(playerid, pickupid);
      • At OnPlayerComandText: if(OnWeaponDropCommand(playerid, cmdtext) == 1) return 1;
      • At OnGameModeExit or OnFilterScriptExit: OnWeaponDropExit();
    • Compile the script and run your server.
    • Enjoy!
Any pictures? Any bugs?
  • There is a bug at the GetPlayerWeaponData function. Sometimes not all weapons get created with correct ammo. (Reported)
  • If you find some others, please report them here, so I can fix them.
Credits: Download Links:
  • Filterscript Version:(Recommended!)

    Readme!
  • Include Version: (Only recommended for people who know how to handle with includes)

    Readme!
  • In the attachments you can directly download the AMX and the PWN file if you wish.

Feel free to modify the Filterscript/Include in any way you want. Of course I'd be happy if you give me /credits.
If you have any questions or ideas or bugs feel free to post them here.
Now enjoy the FS, and please leave your comments & opinions!!



Greetings,
Jeffry


Best Replies:
Quote:
Originally Posted by juraska
Посмотреть сообщение
Good job Jeffry.
Quote:
Originally Posted by KnightRiderUGP
Посмотреть сообщение
These are great Jeffry (as always), specially since this was one of ur first ones. Well as i've already said to you, i'll be using this on my server
Quote:
Originally Posted by HyperZ
Посмотреть сообщение
Well done Jeffry
Reply
#2

woow, really what I was wanting XD. Just was lazy to do that. Really nice
Reply
#3

Wow awesome
Reply
#4

Good Job.
Reply
#5

Good job Jeffry.
Reply
#6

Awsome I'll try this out. Thanks!
Reply
#7

The drop weapons are as pickups or objects?
Reply
#8

Thanks everyone.


Quote:
Originally Posted by Anthony_prince
Посмотреть сообщение
The drop weapons are as pickups or objects?
They drop as pickups. You can pick them up by walking through them.
Reply
#9

Quote:
Originally Posted by Jeffry
Посмотреть сообщение
Thanks everyone.



They drop as pickups. You can pick them up by walking through them.
understood. good job its useful
Reply
#10

Quote:
Originally Posted by Anthony_prince
Посмотреть сообщение
understood. good job its useful
Okey. Thank you.

More comments? Please leave your opinion! Thank you.
Reply
#11

wow good job.thanks
Reply
#12

Don't exists bug on GetPlayerWeaponData, the weapon pickups have a amount of ammo by default.
Reply
#13

Quote:
Originally Posted by CyNiC
View Post
Don't exists bug on GetPlayerWeaponData, the weapon pickups have a amount of ammo by default.
This FS does not use the default ammount of ammo. They will give you (In 99%) the ammo which the player had.
Reply
#14

mmm i see
Reply
#15

Nice script i like it
Reply
#16

Nicee =)
Reply
#17

I made a mirror, it has everything in the folder it should go in, plus a readme;
http://solidfiles.com/d/a1d8/
Reply
#18

Quote:
Originally Posted by lowrida018
View Post
I made a mirror, it has everything in the folder it should go in, plus a readme;
http://solidfiles.com/d/a1d8/
Ok. Thanks.

If you have any suggestions or questions feel free to ask!
Else, please leave your opinions. Thanks.
Reply
#19

very good filterscript i will try it now
Reply
#20

Code:
error 004: function "DropPlayerWeapons" is not implemented
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)