• 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/

Progress on a Mutator to change artillery sounds!

Cwivey, I'll PM you the source when I get a chance later today.

Essentially what the mutator does is override ModifyPlayer and give every player a new Inventory object I call "SoundSwapper."

Code:
function ModifyPlayer(Pawn Other)
{
	local ROPawn P;
	
	Other.ClientMessage("SoundMutator Loaded");
	
    P = ROPawn(Other);
	if (P != None)
	{
		P.ClientMessage("Added SoundSwapper to this client."); 
		P.CreateInventory(class'SoundMutator.SoundSwapper');
	}
	Super.ModifyPlayer(Other);
}

SoundSwapper's PostBeginPlay calls SetTimer(2,true), causing SoundSwapper's timer function to be called every 2 seconds. The timer function looks through every ROArtillerySpawner and modifies it appropriately.

I haven't yet tested this on a dedicated server to see if the code executes on any client connecting (I think it should, because SoundSwapper's Role is ROLE_SimulatedProxy) to a server. Does anyone know how to test that sort of thing?

Edit: Fisher, I haven't look into that but it should be possible. It MAY be an issue with the method I use because it must iterate through EVERY object of a particular class, which is inefficient anyway. I have to use another iterator each time I want to change something different, and I run each iterator every two seconds! They can pile up and kill performance. However, I'll see what I can do.
 
Last edited:
Upvote 0
New video:


RO2 Artillery Sounds Mutator - Artillery (Guns) Test - YouTube


If anyone can create a similar, cleaner version of the incoming sound in the video I'd really appreciate it, because it's from a youtube video and the quality isn't that great. I also need an incoming rocket sound, not like in the other video but the sound of one about to hit you: a high pitched shriek, like this:

guy nearly gets hit by rocket when it fails to explode - YouTube

around 35 seconds.

Everyone, thanks for the praise! It makes the hours worth it.
 
Last edited:
Upvote 0
I've been looking into including supersonic cracks and louder impacts. It MIGHT be possible, lol. ;)

I will say that I've greatly increased the efficiency of the code with respect to timers and iterators... so if I do find a way it'll be much more feasible to implement it in this mutator.

EDIT: Also, I HAVE switched the grenade sounds!
 
Last edited:
Upvote 0
I've been looking into including supersonic cracks and louder impacts. It MIGHT be possible, lol. ;)

I will say that I've greatly increased the efficiency of the code with respect to timers and iterators... so if I do find a way it'll be much more feasible to implement it in this mutator.

EDIT: Also, I HAVE switched the grenade sounds!

Oh god, this just gets better and better...will you put up a demo of the new nade sounds?
 
Upvote 0