Explosion sound stops working with projectile extension

I have been making a pretty extensive game and I have different starting points and saves where I start over. I discovered the bug when I went to my old save which wasn’t using the create projectile extension and the explosion sounds extension together. I then enabled the projectile extension with explosion sound extension and that makes all the explosion sound extensions appear but create no sound. Hopefully, this is fixed soon because I am trying to make a quality game and community that is fun for everyone thanks. Also,

The projectile Code needs more options like sound for creating the projectile as well as sound for when it expires/explodes because you don’t get any control over that and the explosion only works half the time. If there are any workarounds let me know guys thanks.
4/24/23

Yeah the backward portability is scrapped with OW2 updates schedule, but i can’t reproduce that issue, the explosion sounds seem to work fine, after around an hour of testings with AI since the last patch, for me. For soley sound effects are you sure you set Radius/Loudness/Volumn to 100 before editing your mode with projectiles?

3 Likes

yeah, I set it to 200 which is even louder then 100 I tested different volumes does not work with the projectile extension from what I have seen. I already made a bug patch forum but currently haven’t received any actual help except for some ideas that they thought were causing me not to hear the sound. I have an older version of my game mode that doesn’t use the projectile extension but instead uses effects to create projectiles but it takes up way to much code space for something so simple and is more limited since I can make Genji shurikens and other cool effects. If you have any fixes plz let me know I’ve been working on this game for a long time.

The only fix is straight forward let it stay at 100, cause sound scales totally different to the visual size of the other effects, and the max volumn should be 100. What is with other audio input/output effects by the actual game are they functioning fine? Checked that the right audio device is catched? Updated operating system and hardware drivers? What other values did you put in below or above 100? Lower should dump the sound a littel bit down, while above should have no effect. Did you set the explosion radius in create projectile above 0, could also be a fraction like 0.01? Other then that you can tweak around with my testing code below to see if it might have something to do with upgrading game modes, which means you need to redo everything from scratch and to be 100% clean do not copy paste from your corrupted mode, but i can’t tell and just give you as an extern my playground code here:

variables
{
	player:
		0: TCBRampageTarget
		1: TCBSwordImageStart
		2: TCBSwordImageEnd
		3: TCBEffects
		4: FoldRadius
		5: Temp
}

rule("Senbonzakura Init")
{
	event
	{
		Ongoing - Each Player;
		Team 1;
		Genji;
	}

	actions
	{
		Event Player.TCBRampageTarget = Null;
		Event Player.TCBSwordImageStart = Null;
		Event Player.TCBSwordImageEnd = Null;
		Event Player.TCBEffects = Array();
		Event Player.FoldRadius = 0;
		Set Primary Fire Enabled(Event Player, False);
		Set Secondary Fire Enabled(Event Player, False);
	}
}

rule("Senbonzakura Reset")
{
	event
	{
		Ongoing - Each Player;
		Team 1;
		All;
	}

	actions
	{
		Event Player.TCBRampageTarget = Null;
		Event Player.TCBSwordImageStart = Null;
		Event Player.TCBSwordImageEnd = Null;
		Event Player.TCBEffects = Null;
		Event Player.FoldRadius = Null;
		Set Primary Fire Enabled(Event Player, True);
		Set Secondary Fire Enabled(Event Player, True);
	}
}

rule("Thousand Cherry Blossoms")
{
	event
	{
		Ongoing - Each Player;
		Team 1;
		Genji;
	}

	conditions
	{
		Is Alive(Event Player) == True;
		Is Using Ultimate(Event Player) != True;
		Is Button Held(Event Player, Button(Primary Fire)) == True;
	}

	actions
	{
		Create Projectile(Genji Shuriken, Event Player, Eye Position(Event Player) + World Vector Of(Vector(3 * 0.500, 0, 0), Event Player,
			Rotation) + World Vector Of(Vector(Cosine From Degrees(35), 0, 2), Event Player, Rotation), Null, To World, Damage,
			Opposite Team Of(Team Of(Event Player)), 50, 0.500, 0.020, Tracer Recall Disappear Effect, Ana Biotic Grenade Explosion Sound,
			0.020, 100, 5, 0, 3, 0);
		Wait(0.016, Ignore Condition);
		Create Projectile(Genji Shuriken, Event Player, Eye Position(Event Player) + World Vector Of(Vector(0, 0, 2), Event Player,
			Rotation), Null, To World, Damage, Opposite Team Of(Team Of(Event Player)), 50, 0.500, 0.020, Tracer Recall Disappear Effect,
			Ana Biotic Grenade Explosion Sound, 0.020, 100, 5, 0, 3, 0);
		Wait(0.016, Ignore Condition);
		Create Projectile(Genji Shuriken, Event Player, Eye Position(Event Player) + World Vector Of(Vector(3 * -0.500, 0, 0),
			Event Player, Rotation) + World Vector Of(Vector(-1 * Cosine From Degrees(35), 0, 2), Event Player, Rotation), Null, To World,
			Damage, Opposite Team Of(Team Of(Event Player)), 50, 0.500, 0.020, Tracer Recall Disappear Effect,
			Ana Biotic Grenade Explosion Sound, 0.020, 100, 5, 0, 3, 0);
		Wait(1, Abort When False);
		Loop;
	}
}

rule("Thousand Cherry Blossom Rampage")
{
	event
	{
		Ongoing - Each Player;
		Team 1;
		Genji;
	}

	conditions
	{
		Is Alive(Event Player) == True;
		Is Using Ultimate(Event Player) != True;
		Is Button Held(Event Player, Button(Secondary Fire)) == True;
	}

	actions
	{
		Disallow Button(Event Player, Button(Secondary Fire));
		Event Player.TCBRampageTarget = Player Closest To Reticle(Event Player, Opposite Team Of(Team Of(Event Player)));
		Event Player.TCBSwordImageStart = Ray Cast Hit Position(Eye Position(Event Player), Eye Position(Event Player) + World Vector Of(
			Vector(0, 2, 0), Event Player, Rotation) + World Vector Of(Forward, Event Player, Rotation) * 2, All Players(All Teams),
			Event Player, True);
		Event Player.Temp = Event Player.TCBSwordImageStart;
		Event Player.TCBSwordImageEnd = Event Player.TCBSwordImageStart + Vector(0, -4, 0);
		Create Projectile Effect(All Players(All Teams), Mei Icicle, Event Player, Event Player.TCBSwordImageStart, Direction Towards(
			Event Player.TCBSwordImageStart, Event Player.TCBSwordImageEnd), 0.100, Visible To Friendly To Position Direction and Size);
		Event Player.TCBEffects[0] = Last Created Entity;
		Create Effect(All Players(All Teams), Cloud, Color(Rose), Evaluate Once(Ray Cast Hit Position(Eye Position(Event Player),
			Eye Position(Event Player) + World Vector Of(Vector(0, -1, 0), Event Player, Rotation) + World Vector Of(Forward, Event Player,
			Rotation) * 2, All Players(All Teams), Event Player, True)), Event Player.FoldRadius, Position and Radius);
		Event Player.TCBEffects[1] = Last Created Entity;
		Chase Player Variable At Rate(Event Player, TCBSwordImageStart, Event Player.TCBSwordImageEnd, 2, Destination and Rate);
		Chase Player Variable At Rate(Event Player, FoldRadius, 10, 2, Destination and Rate);
		Wait Until(Event Player.TCBSwordImageStart == Event Player.TCBSwordImageEnd, 3);
		Stop Chasing Player Variable(Event Player, TCBSwordImageStart);
		Destroy Effect(Event Player.TCBEffects[0]);
		Event Player.TCBEffects[0] = 0;
		For Global Variable(I, 0, 10, 1);
			Create Homing Projectile(Genji Shuriken, Event Player, Event Player.Temp, Direction Towards(Event Player.Temp,
				Event Player.TCBRampageTarget), To World, Damage, Opposite Team Of(Team Of(Event Player)), 100, 0.500, 0.020,
				Tracer Recall Disappear Effect, Ana Biotic Grenade Explosion Sound, 0.020, 110, 3, 0, Event Player.TCBRampageTarget, 0.800);
			Wait(0.250, Ignore Condition);
		End;
		Stop Chasing Player Variable(Event Player, FoldRadius);
		Destroy Effect(Event Player.TCBEffects[1]);
		Event Player.TCBEffects[1] = 0;
		Event Player.TCBRampageTarget = Null;
		Event Player.TCBSwordImageStart = Null;
		Event Player.TCBSwordImageEnd = Null;
		Event Player.FoldRadius = 0;
		Wait(2, Ignore Condition);
		Small Message(Event Player, Custom String("Scattered!"));
		Allow Button(Event Player, Button(Secondary Fire));
	}
}
2 Likes

I don’t get it how is my mode corrupt? I did port it from ovw 1 to 2 since it’s that old but I do not understand the code which works anyways and can somehow break the sound in the game. In terms of other sounds they work fine in my game mode so I don’t understand why explosion sounds is the only thing not working which happened once I enabled projectile extension on the game. I did disable energy extension effects but that doesn’t have anything to do with sound. I can do this test thing and I get to you back on it thanks. Also, thousand Cherry Blossom Rampage is a Bad “–s” name can I use it in my game mode?

Edit: You code on a fresh save work for me as far as I can tell so I may have to look into it. Starting over would be detrimental because this isn’t a small game by any means. Also, I was wondering if you would update the code you made for Genji to make him disappear and create a storm of shurikens where he is standing kinda like a Doomfist ultimate. I can use it in my game as one of his upgrade options and Ill give you the credit but so far I am learning and this has been the most helpful post so far thanks. If you want you can friend me at layslegend4#1110 if you want to get back to me or just keep posting in this forum. Also another thing the explosion effect and sound for the shurikens only work half the time which is a bug I reported for blizzard and have no idea when it will be done. Another thing to be clear I am simply trying to use explosion sound by itself not in the create projectile action and it hasn’t been working. I also thought of another way to show you my problem is invite you to the lobby to show you what it is and what I can do to fix it.

2nd edit: I was able to recreate my problem instantly so its not the code thats bugged. The explosion sounds extension does not work with projectile extension so I don’t know how you will be able to help me there.

Then share your code so, we can try it out, to be certain that it may be bugged, for the projectile part it works for me fully, no strecthings nor delays or abrupt interruptions in continuous sequences of executing the rules. You can use the name as a pseudonym or fan made ability name as you desire and wish even change it, the names are references to an beloved anime of mine from Bleach ( might tick something :smiley: ), my shared snippets are 100% open source, i also do not demand any credits, and leave it up to the user, end-user, mid-user or co-authors. About the upgrade its a good idea, still need to think of how it should look like and work, though the creation of projectiles is limited, the previous projectiles need to finish their lifetime to be freed from memory, so the next iteration of spamming projectiles may occure, some design mindscapes come to my mind about that, that is non-understandable by others and would explode this small intended reply. So if you wouldn’t mind to share your code part where the explosion sound are meant to head up, i could do some test, if i literally hear them, my eyes are bad but my ears should notice it :confused: .

2 Likes

My code isn’t open source yet because I want a claim on my idea/game and wish to make a community however since you open source your code if you friend me I will give you the code personally in good faith. My game adds extensive talent and level-up system that lets you pick your talents like “Heros Of The Storm” and I have several heroes done. This game definitely could build up some traction which is what I’m hoping for. I don’t mind you using it and improving it and sending it back as well as keeping it for yourself since you are helping me. I have currently in my latest build Reinhardt, Brigitte and Doomfist done although I have other heroes done as well. Friend me and Ill send it to you.

Edit: Also I was able to recreate the problem on a fresh workshop with no rules just 1 rule running it and the extensions so I really think it’s a bug.
1st. I turn on projectile extension, explosion extension, buff status, and debuff status extension. Then I create 1 rule when genji attacks with his primary play effect ashe explosion sound (not exact name) and no sound plays.

I stumbled and tested around again, and enabled the extension you mentioned in your edit too as:

And at first if i let the playing effect’s position stay at Event Player, especially for some explosion sounds like Ashes Dynamite Explosion Sound, nothing happens, some sounds work some not. Turns out after looking at some reference sheets on [Preformatted text](https://workshop.codes/wiki/articles/workshop+extensions+-+explosion+sounds+reference+sheet), some effects won’t play when the position is Event Player, or -by my additional tests- the position is dynamically calculated within that action and not stored in a variable before hand. To fix that according to the sheet is to play with colors, and using positions like Eye Position, Position Of and any stored postion with a variable and avoid Event Player for most sounds. By changing the postion to Position Of as an example in my test, the sound of the exploding dynamite works, ofc the farer away the position is from yourself, the more quite it sounds, but may sound louder to other players who are near by the set position (which i couldn’t test).

3 Likes

Wow this is extremely useful information I didn’t think of using the position of but that itself might fix it ill have to test it out to be sure. I was wanting to see what type of code you developed I was gonna send you a friend request but I can’t see your profile. I also was wanting to see if you wanted to start a forum for idea for characters and abilities that players can discuss and may want and see if its possible to replicate.