Left 4 Dead 2

Left 4 Dead 2

133 ratings
Share Ammo With Teammates
   
Award
Favorite
Favorited
Unfavorite
Game Content: Scripts
Game Modes: Single Player, Co-op
File Size
Posted
Updated
11.587 KB
30 Apr @ 1:49am
1 May @ 2:19pm
2 Change Notes ( view )

Subscribe to download
Share Ammo With Teammates

Description
This customisable mod lets you share your spare ammunition with a teammate who's been a little too trigger happy.

To share your ammo, equip your primary weapon and shove a teammate while holding reload. Your teammate must be using a primary weapon that uses the same type of ammo. Your clip will be emptied, and your teammate will gain reserve ammo based on how much ammo was in your clip.

By default, any weapon can share its ammo with another weapon that uses the same type of ammo. So the M16 can share its ammo with the AK47, but not an Autoshotgun or Hunting Rifle. However, you can edit the mod by changing the values in "ems/share_ammo/ammo_types.txt", letting you alter which weapons can share ammo with each other. This can be useful if you play with custom weapon scripts that change what ammo type each gun uses, or if you'd just like the script to be a little more lenient, such as by letting auto and pump shotguns share ammo.
43 Comments
Geebanger0  [author] 11 May @ 2:35pm 
:Eddie:
gelgoog 11 May @ 12:53pm 
Yes, I want to shoot civilians. I mean zombies. Zombies that run away from you but also resemble humans.
kurochama 11 May @ 1:42am 
Basically that's like the gunshot attracts horde, but in reverse version then :steamhappy:
Geebanger0  [author] 11 May @ 1:35am 
so its just... No Russian but in L4D2?
gelgoog 11 May @ 1:11am 
Geebanger0, you are my best best friend in the whole wide world. I have an idea. What if the common infected were scripted to run away from you instead of running at you when provoked? Make all of the common infected act like real people running away from crazed gunmen. If you do this, I will put human textures on all the zombies, and my urges will be put to rest at last. Geebanger0, you know who I am. We're best friends. Do this for me.
Ryan the Womb Raider 6 May @ 11:16am 
THIS MOTHERFUCKER RELEASES PEAK AFTER PEAK AFTER PEAK
BabaWings 6 May @ 10:51am 
I was here too
Milcoенг 5 May @ 7:12am 
8
9
789
789
78
9980
89
0
90
890
890
89089000000
89
08
9089
0
890
890
ШЩЗШ
ЩЗШЩ
ЗШЩЗ
Ш
ЗШ
ЩЗШ
ЩЗ
890
890
890
kurochama 3 May @ 11:13pm 
@Geebanger0 , some few tricks that might help you find some clues to spawn custom ammo piles:
1. On "round_start", spawn a new "weapon_ammo_spawn" to replace the existing ammo by using "FindByClassname" with "RandomInt" check to randomize the results.
2. On the weapon spawn table, add:
model = ".../ammomodel.mdl"
3. Change the model to suit the ammo type (examples: change it to deployed incendiary ammo model)
4. On "player_use", on the entity that player uses, check if the entity is ammo pile, & if the model name matches the custom ammo model you put on the spawn table.
5. If the model matches, trigger an upgrade & at the same time remove it.

I ever used this trick to spawn a custom ammo piles with gnome skin, to make it look funny to see a little guy giving ammo :steamhappy:
Kouga 3 May @ 9:31pm 
ill do just that