Regenerate A Specific Custom Ammo Type When Weapon is Idle

Started by Balistine, February 01, 2021, 03:35:46 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Balistine

Hi, I am completely new to modding Doom 3 and scripting in general. I need a way to recharge a custom ammo type when the weapon is in its idle state. How can I go about doing that?

The Happy Friar

#1
Easiest way would be to spawn ammo pickups at your location every X seconds while in idle function in the script.  Then the player would pickup the ammo as long as you need more.
EDIT: check out the weapon grenade script in my mod here: https://www.moddb.com/mods/the-happy-friars-last-stand/downloads/the-happy-friars-last-stand-v12-beta-2
when you explode the grenade in your hand it spawns a med kit at your location.  You'd want something similar, but spawns ammo vs med kits.