ileblanc wrote:Is there a way to make backpack only add 25% more ammo capacity instead of doubling it? After playing Project Brutality for a while I got near infinite ammo and the fun was completely gone.
I agree a setting menu or Cvar would be nice to have.
In the meantime its possible to manually fix it too:
1. Open backpack.pk3 with IZArc or another unzip program.
2. Find double.txt in the /source folder and open it with notepad - I used IZArc's right-click -> "view in notepad" to do this.
3. Find this middle section of the code:
Code: Select all
action void _DoubleAmmoCapacity(class < Ammo > type) {
Inventory item = FindInventory(type);
if (!item) {
item = GiveInventoryType(type);
item.amount = 0;
}
if (item.maxAmount * 2 >= 0) { //avoid ineger overflow
item.maxAmount *= 2;
} else {
item.maxAmount = 2 ** 31 - 1;
}
}
4. Notice the "2" in the three spots over there. Change that to 1.25 (for +25% ammo) or 1.1 (for +10% ammo) or 1.2 (for +20% ammo).
It should look like this:
Code: Select all
action void _DoubleAmmoCapacity(class < Ammo > type) {
Inventory item = FindInventory(type);
if (!item) {
item = GiveInventoryType(type);
item.amount = 0;
}
if (item.maxAmount * 1.25 >= 0) { //avoid ineger overflow
item.maxAmount *= 1.25;
} else {
item.maxAmount = 1.25 ** 31 - 1;
}
}
5. Save the file and close it.
6. In IZArc, it might ask "double.txt was modified, do you want to update it in the archive?" say "Yes".
Done! Now the mod should work the way you want to.