[L4D2] Shotgun and bolt rifle fire rate and reload modification?
As you may know, the fire rate and reload speed for the pump shotguns and auto shotguns in L4D2 are hardcoded and can't be modified through weapon scripts, unlike all the other guns. The CS bolt action rifles also cannot have their fire rate modified (the reload can be, since they use detachable magazines).
Is it possible to make a SourceMod plugin that can change those properties of the weapons? |
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
|
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
Quote:
In order to speed up the reload of the pump shotgun, I would need to: 1. Apply a speed modifier when the pump shotgun is reloading. 2. De-apply the speed modifier whenever anything else happens? And if I forget to check everything then it results in a bug/unintended behavior. Isn't there a way to more directly modify the code of the pump shotgun specifically? |
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
The WeaponHandling API is already pretty direct with what you want. It hooks all the functions of the player's weapon and allows users to change the speed of those functions.
You can do something like this: PHP Code:
|
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
Quote:
You have no idea how thankful I am. I've been looking for a plugin that does exactly this (on and off, half-assedly) since 2017. I was literally writing up a request about this until I decided to take yet another look at previous post mentioning shotguns reload before submitting. The fact this this was never made before baffles me. |
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
PHP Code:
|
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
I compiled that exact code and it worked just fine. Make sure you have WeaponHandling.inc inside your include folder.
Code:
//SourceMod Batch Compiler |
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
PHP Code:
Thanks. |
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
Quote:
In 3rd person the reload speed is normal even when i got them set much much faster. Can you add 3rd person code to this at all please i'd really appreciate it :bee: |
Re: [L4D2] Shotgun and bolt rifle fire rate and reload modification?
I've just tested this again more, the shotguns animations seem to work fine and are just as fast in 3rd person as in 1st person.
I added most the other guns from the game to this script with 75% increase in speed for test and whilst they had fast reload in 1st person they were slow in 3rd person view. Not really sure why only the shotgun animations reload faster in 3rd person and the others do not. Can this script be adjusted to work fast for all guns in 3rd person view :?: |
All times are GMT -4. The time now is 12:57. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.