

Now let’s make the file that will be injecting code into a. So, for information’s sake, I still recommend adding crossbow damage stat to a. But even though a does not control arrow damage, it still controls the crossbow damage that appears on the weapon stats box. _mode_data =, “You said that a controlled arrow damage, not a!” Well, yes, we really don’t need to add the damage stat to a, the file whose code will be injected into a. The default values of the variables we will be modifying are as follow: For the Little Friend, the weaponID is named contraband. WeaponID refers to the internal weapon name Payday 2 uses. Your weapon variables will be set up like this:

In between old_init(self, tweak_data) and end will be your weapon variables. Open a and set up the file like this:įunction WeaponTweakData:init(tweak_data) Inside MyWeaponMods, create a LUA file with a notepad program named a. As a bullet based weapon, we will be injecting code into a.Īfter installing BLT, create a folder inside the Payday 2 mods folder. This will entail nerfing the damage, while increasing the amount of ammo you can pickup and carry along. Let’s say we want to make the Little Friend act like how it did in Scarface, an assault/battle rifle that sprays bullets everywhere instead of firing single shots like a DMR. Other players that join your game will not be able to use these mods and these mods will be disabled if you join another player’s game. Note that these mods will only work with game hosts. Just read in the instructions on that page to set up BLT. The most popular LUA injector is the Payday 2 BLT. Instead, you will need something called a LUA hook which will inject your code into the game.

To modify these stats, you will not be modifying a or a directly, as they are buried inside Payday 2’s game files. a also defines a lot of other different things, such as voice lines, but for the sake of this article, we will only be looking at what it does with respect to weapon damages. a contains the stats for non-bullet projectile damages (arrows, rockets) as well as throwable damages. a contains the stats for all the weapons (concealment, fire rate, etc.) except for non-bullet projectile damage. As their extension implies, these files are in the LUA format and can be edited with a notepad program. There are two main files we will be working with: a and a. Well, you can do all of that, and some more, with Payday 2 LUA mods.įirst, let’s go over what Payday 2 files control weapon damages. Ever wish you could make certain Payday 2 weapons more useful and balanced? Maybe you wanted to modify damage, ammo pickup or rate of fire.
