Dandie Posted September 22, 2013 Share Posted September 22, 2013 (edited) Here's the situation. I have a gun that I want to make reloadable only via workbench, and also I want it to have only one clip of ammunition (so when I wasted all the bullets (there are 5 of them), I need to go to workbench).I already did following:1. unique ammo, that has 100% chance of recovering unique "cases";2. Recipes that use these cases as ingredients for "reloading".3. Tried to make sure, that the amount of (ammo+cases) is always equials to 5 (i.e. 1 ammo 4 cases, 2 ammo 3 cases, etc). I need a script for a weapon, that does the following:On first pickup, it will add 5 unique ammo.When weapon is removed, it will need to check players inventory and remove all unique ammo and cases as well, remember these numbers and store them in some sort of variables (I don't know much about scripting, but I guess those must be globals).Upon further pickups, returns appropriat amount of ammo and cases. Bonus: I also need a script that prevents ammo and cases from being removed independently from inventory (with a custom message or without any message showing while trying to do so), i.e. while weapon is in inventory, then ammo and cases cannot be dropped. Edited September 22, 2013 by Dandie Link to comment Share on other sites More sharing options...
Recommended Posts