Bolt Only Mutator

  • Please make sure you are familiar with the forum rules. You can find them here: https://forums.tripwireinteractive.com/index.php?threads/forum-rules.2334636/

ERK

FNG / Fresh Meat
Nov 22, 2005
322
37
0
47
Texas
Bolt Only Mutator:
Replaces all primary weapons with bolt rifles. All secondary weapons/items weren't touched, so any grenades/pistols/binocs/satchels/etc... will still be equipped per class.

All credit goes to Sent666 since this mutator is an modified version of his Pistol-Only v1.0 mutator found here.

I'm thinking of making another mutator to allow server admins to choose what primary, secondary and inventory items they want per map basis.

This isn't posted in the Final Mutator section because I currently don't run my own server, so if any server admins out there can test this, I'd be grateful.

While I was at it, I compiled a second version for Mare Nostrum.

For those interested, here are the scripts:

ROBoltMut
Code:
class ROBoltMut extends Mutator;
function PreBeginPlay()
{
local RORoleInfo Bolt;
super.PreBeginPlay();
foreach AllActors(class'RORoleInfo',Bolt)
{
if(Bolt.Side==SIDE_Axis)
{
Bolt.PrimaryWeapons[0].Item=class'ROInventory.Kar98Weapon';
Bolt.PrimaryWeapons[0].Amount=1;
Bolt.PrimaryWeapons[1].Item=none;
Bolt.PrimaryWeapons[1].Amount=0;
Bolt.PrimaryWeapons[2].Item=none;
Bolt.PrimaryWeapons[2].Amount=0;
}
if(Bolt.Side==SIDE_Allies)
{
Bolt.PrimaryWeapons[0].Item=class'ROInventory.MN9130Weapon';
Bolt.PrimaryWeapons[0].Amount=1;
Bolt.PrimaryWeapons[1].Item=class'ROInventory.M38Weapon';
Bolt.PrimaryWeapons[1].Amount=1;
Bolt.PrimaryWeapons[2].Item=class'ROInventory.M44Weapon';
Bolt.PrimaryWeapons[2].Amount=1;
}
}
}
MNBoltMut
Code:
class MNBoltMut extends Mutator;
function PreBeginPlay()
{
local RORoleInfo Bolt;
super.PreBeginPlay();
foreach AllActors(class'RORoleInfo',Bolt)
{
if(Bolt.Side==SIDE_Axis)
{
Bolt.PrimaryWeapons[0].Item=class'ROInventory.Kar98Weapon';
Bolt.PrimaryWeapons[0].Amount=1;
Bolt.PrimaryWeapons[1].Item=none;
Bolt.PrimaryWeapons[1].Amount=0;
Bolt.PrimaryWeapons[2].Item=none;
Bolt.PrimaryWeapons[2].Amount=0;
}
if(Bolt.Side==SIDE_Allies)
{
Bolt.PrimaryWeapons[0].Item=class'MNInventory.SMLE1MK3Weapon';
Bolt.PrimaryWeapons[0].Amount=1;
Bolt.PrimaryWeapons[1].Item=none;
Bolt.PrimaryWeapons[1].Amount=0;
Bolt.PrimaryWeapons[2].Item=none;
Bolt.PrimaryWeapons[2].Amount=0;
}
}
}
Enjoy.

Edit: Removed Attachments to fully test the mutators online.
 
Last edited:

worluk

FNG / Fresh Meat
Nov 21, 2005
2,226
85
0
hm, does it work on the server? I seem to remember there being some problems with replication with the Pistol mutator.
 

ERK

FNG / Fresh Meat
Nov 22, 2005
322
37
0
47
Texas
hm, does it work on the server? I seem to remember there being some problems with replication with the Pistol mutator.

Hopefully Grim over at =db= will get this tested on their server soon. I did some reading on replications and reworked the code if the above doesn't work.

Edit: Removed code for further testing.
 
Last edited:

worluk

FNG / Fresh Meat
Nov 21, 2005
2,226
85
0
Let me know if it works.
I might be wrong, but i think you have to set the role of the mutator to make the PostNetBeginPlay getting called on the client. Not sure if you have to set bAlwaysRelevant to true.
 

walker77rus

FNG / Fresh Meat
May 2, 2007
9
2
3
It is the final version?
Also it is necessary to disable:
- Artillery Strike
- Vehicle
- Grenades
- Secondary Weapons
- Satchels etc