Left 4 Dead 2

Left 4 Dead 2

[M60] M60 script (TLS)
141 Comments
Alex_D #NoWar  [author] 21 Mar @ 12:22pm 
I could set the ammo type to hunting rifle's, but it wouldn't instagib the common infected.
IS4 20 Mar @ 1:10pm 
You can make a script that has 150 and 150 reserves, like on some servers. plis
Alex_D #NoWar  [author] 16 Mar @ 11:03am 
It is possible to do so, but it is janky, and would differ wildly from model to model.
Pixel 15 Mar @ 10:10pm 
can you edit the reload time?
Alex_D #NoWar  [author] 27 Dec, 2024 @ 10:38am 
It does not work online, and offline it requires a restart when first subscribing.
doi buon jqk 27 Dec, 2024 @ 9:45am 
not work !!!!!!!
Alex_D #NoWar  [author] 15 Dec, 2024 @ 11:35am 
No shit. This is mentioned in the description, by the way.
wo bist du 15 Dec, 2024 @ 11:07am 
it would drop automatically after clearing all ammo inside the magazine:steamsad:
Alex_D #NoWar  [author] 28 Oct, 2024 @ 10:07am 
Just checked. My mod still works like before.

It's probably either a custom server setting or some script conflict.
Colkillervin 27 Oct, 2024 @ 8:36pm 
for some reason the reserve ammo became just 100 instead of the 800
Alex_D #NoWar  [author] 8 Sep, 2024 @ 12:17pm 
It's a feature... of the default M60 that is hard coded to be discarded when it's emptied.

You might want to try "M60 Fixes" or whatever the vscript mod is called that actually prevents the M60 from dropping.
DrinkingBuddies 7 Sep, 2024 @ 11:59am 
Very nice mod, thank you. However, when I use up all my loaded ammo, the gun automatically drops instead of reloading even though I still have ammo left. Is this a bug?
Alex_D #NoWar  [author] 7 Jul, 2024 @ 2:15am 
If I do (by using a different ammo type), it will lose instagibbing. There's better alternatives made by less conventional means; try searching for "m60 fixes" or whatever its name was. It actually prevents the M60 from dropping on empty.
Party123 6 Jul, 2024 @ 11:23pm 
Can you reduce the amount of reserve ammo to 300 rounds? I like it, but the amount of ammunition is too much to the point of not being fun to play.:steambored::steamfacepalm:
That viking who procrastinates 30 May, 2024 @ 6:13pm 
Works pretty well with the custom mk46 also
Alex_D #NoWar  [author] 10 Feb, 2024 @ 10:59am 
@铃科百合子, you could very easily do so yourself, but keep in mind that you cannot exceed 250 rounds in the magazine. Well, you can, but it's wonky and will not work properly.

The 110 rounds are supposed to imitate the realistic belt capacity with some room for error. But I won't lie, I often lose the gun myself in the heat of battle. I just treat this as overheating failure.
Alex_D #NoWar  [author] 10 Feb, 2024 @ 10:56am 
@ZachNohKap, why would this need to be updated? It's final, works in every conceivable way that can be achieved by a minimalistic script edit, and does everything it's designed for.
ZachNohKap 9 Feb, 2024 @ 8:21pm 
this has not been updated in almost 4 years.
铃科百合子 9 Feb, 2024 @ 2:02am 
Can the author increase the amount of ammunition in the magazine? When fighting tanks, I often forget to change ammunition, resulting in the gun being constantly discarded!
AyayaNakiriAkira 8 Dec, 2023 @ 11:52am 
good
Alex_D #NoWar  [author] 1 Nov, 2023 @ 3:02am 
It largely depends on the weapon model's reload animation, but it can be overriden by adding ReloadDuration 5.5 into the script to make it reload in 5.5 seconds. It's a bit janky but it works.
IndianaCr0ft 30 Oct, 2023 @ 3:56pm 
Is there a way to modify the reload speed, I want it to reload a little bit slower
Alex_D #NoWar  [author] 19 Oct, 2023 @ 11:59am 
The scripts are a bit finicky, so you have to restart the game at least once to get them to work. Also make sure there's nothing conflicting with this addon, such as legacy HUD icon mods or weapon rebalance packs. Or even an M60 skin that has its own script for whatever reason.
Shadowknight 19 Oct, 2023 @ 9:57am 
May i ask how to make the script work? I downloaded the addon but when i just in game ( solo campaign) the M60 isn't reloadable still has the same ammo count how to fix?
Alex_D #NoWar  [author] 9 Aug, 2023 @ 3:16pm 
The rate of fire is determined by CycleTime. Cycle time is how many seconds it takes between shooting a bullet. If you're looking for a 600 RPM (rounds per minute) rate of fire, divide 60 seconds by that number (60 / 600 = 0.1, so the CyclicRate needs to be changed to 0.1), 1200 RPM (like an MG42) would require 0.05 cycle time.
Kraft 9 Aug, 2023 @ 2:39pm 
is there as a way to make the M60 fire faster/any way to make scripts that fit faster firing weapons?
Jboy9786 4 Aug, 2023 @ 1:44am 
Mag = 80
Reserve = 400
and were good to go
Alex_D #NoWar  [author] 26 Jul, 2023 @ 8:45am 
Secondary ammo is more of a Half-Life leftover (like underbarrel grenades), I think it is completely unused in L4D2. Reserve ammo is set with convars (one way is to edit gamemodes.txt, but I've never done that), another is change the ammo type in the script.

If you give a submachine gun the assault rifle ammo type, it will have 360 reserve (by default) but receive gibbing abilities. Grenade launcher ammo type instagibs common infected and stumbles everyone , including Tanks and Witches, but only has a 30 round reserve and does not actually make the weapon fire grenades. AMMO_TYPE_MINIGUN is essentially the .50 cal type, similar to the M60 ammo type but with a massive 800 reserve. There's also AMMO_TYPE_TURRET, which has 300 reserves and no gibbing.
pet 26 Jul, 2023 @ 5:48am 
Anyway, may I ask how to change the reserve ammo and what the "secondary_ammo" is all about? I won't change the reserve ammo for T1 and T2 weapons as I prefer the default, but prospecting to set reserves for T3.
pet 25 Jul, 2023 @ 1:04pm 
Okay, got it. Thanks for all the details, really appreciate it!
Alex_D #NoWar  [author] 25 Jul, 2023 @ 12:55pm 
Yeah, everything else is more or less correct. ReloadDuration is largely irrelevant for the shotguns due to how animations are coded, but for the most part you can use this guide for reference.

Well, that and the "update" folder having the most up-to-date scripts (this is also why the guide writer couldn't find the M60 script, because it first appears in DLC1).
pet 25 Jul, 2023 @ 12:39pm 
Got loss of words again, sorry. What I meant was "instructions".

Okay, so every instructions provided in that link is still relevant, except for script files, right?
Alex_D #NoWar  [author] 25 Jul, 2023 @ 12:28pm 
Just use Crowbar if you haven't acquired it yet. You can find the download link in the Crowbar steam group on my profile.

Set up games and directories, and go nuts.
Alex_D #NoWar  [author] 25 Jul, 2023 @ 12:24pm 
I dunno about methods. You can use GCFscape or Crowbar to unpack the files you need, and either drag and drop your mod folder onto vpk.exe or let Crowbar do it for you.
pet 25 Jul, 2023 @ 9:27am 
So that's it? What about the other methods?
Alex_D #NoWar  [author] 25 Jul, 2023 @ 9:17am 
Almost entirely outdated. The latest script files are in the "update" folder's pak01_dir, not in "left4dead2".
pet 25 Jul, 2023 @ 9:12am 
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=1060964738
Just wanna ask if this is still the method you're using when editing scripts. I know it's obsolete. Tried it.
Do you have any link of any working modding methods?
CrimsonRam 18 Jul, 2023 @ 6:15am 
Ahh that's why I only find ammo count around 100-200 ish... maybe in the future this won't be a problem.... Anyhow thanks again and have a good one boss!
Alex_D #NoWar  [author] 18 Jul, 2023 @ 2:00am 
Well, it's not hard to make yourself, and there's probably already something like that.

But the scripts do funny stuff if the ammo counter is above 250. The counter is byte-sized, so it glitches around 255. You can end up being unable to equip your M60 if you have a certain number on your ammo counter.
CrimsonRam 18 Jul, 2023 @ 1:54am 
Hey boss, been using your great mod, it's nice to have more ammo for the m60. But do you have a script that has 500-1000 clip size? No reload required...
Alex_D #NoWar  [author] 12 Jun, 2023 @ 3:07am 
A text editor. The weapon scripts are text files; how you get them and pack them into a mod is another thing entirely.
pet 12 Jun, 2023 @ 1:41am 
What software(s) do you use to edit all these weapons stats?
DOOMGUY 12 Mar, 2023 @ 8:22am 
ok
Alex_D #NoWar  [author] 12 Mar, 2023 @ 4:32am 
There might already be one. I'm not planning any script mods at the moment; if anything, I should be updating my old stuff.
DOOMGUY 11 Mar, 2023 @ 9:27pm 
Hey Alex, are you planning on making a RPK (M60) script mod?
Alex_D #NoWar  [author] 19 Feb, 2023 @ 1:55am 
Interesting. Thanks.
ZachNohKap 18 Feb, 2023 @ 4:14pm 
i just found out that you can make the change with vscripts. with this mod it give 300 reserve ammo but adds the ability to refill ammo on the m60 and the gl. however that part of it is broken. the main part is that they keep the instagib properties of the m60 while having a certain amount of reserve. i will link the vscript here https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2002508596
ZachNohKap 16 Feb, 2023 @ 2:25pm 
yeah i dont know why but it was doing it for me beforehand but now its not. idk what it did but it just stopped
Alex_D #NoWar  [author] 16 Feb, 2023 @ 8:23am 
Please do, because I am somewhat interested.
ZachNohKap 16 Feb, 2023 @ 8:20am 
weird. i should check that out.