KadeArchive / Kade-Engine

Kade Engine is a Competitive Rhythm Game engine rewrite for FNF with Quality of Life features included.
https://kadedev.github.io/Kade-Engine/
Apache License 2.0
409 stars 594 forks source link

Bug Report: After dying, in the first 2-3 seconds, the normal music restarts, then turns into the normal gameover music #2800

Closed SkullDollar closed 2 years ago

SkullDollar commented 2 years ago

Please check for duplicates, similar issues or closed issues with the same problem, as well performing simple troubleshooting steps (such as deleting the export folder if it's an issue with compiling, reinstalling Kade Engine) before submitting an issue.

If you are playing a downloaded version of the game, what operating system are you using?

Windows (x86), Windows (x86_64), Linux, or macOS? Specify below. -Windows(x86_64)

What version of the game are you using? Look in the bottom left corner of the main menu.

-0.2.7.1, with the version 1.8.7 of the Kade Engine

Have you identified any steps to reproduce the bug? If so, please describe them below. Use images if possible.

SkullDollar commented 2 years ago

I Would like to also say that i even deleted my savegame, located in the "Appdata\Roaming\kadedev", yet the issue still happens

SilverT4 commented 2 years ago

I saw an issue like this one reported over on the FNF GameBanana. If this was posted by you, then hello, I was the one that suggested you report this here. ANYWAY.

I noticed this issue as well, I'm guessing the game doesn't listen properly when it's told to stop the music/vocals, as for me the music kept going even after the mic dropped. Maybe it's a result of using a newer version of Haxe, although Psych Engine uses 4.2.4 and doesn't have this issue. What I've done in a local build that appears to work is add the following to the GameOverSubstate.hx file, in the update function:

if (FlxG.sound.music.playing && !vibin)
            {
                FlxG.sound.music.stop();
                if (PlayState.instance.vocals != null)
                    PlayState.instance.vocals.stop();
            }

("vibin" is a bool that's set to true with the startVibin variable) I've also added the vocals.stop(); and FlxG.sound.music.stop(); lines to PlayState under each instance of the game being told to switch to the GameOverSubstate. This appears to work.

SkullDollar commented 2 years ago

Hey, thanks for answering! (and yes, i was the one that posted this question gamebanana).

I will try to do what you said, but it's still weird that it happens even in a non-modified version of the game

SkullDollar commented 2 years ago

I saw an issue like this one reported over on the FNF GameBanana. If this was posted by you, then hello, I was the one that suggested you report this here. ANYWAY.

I noticed this issue as well, I'm guessing the game doesn't listen properly when it's told to stop the music/vocals, as for me the music kept going even after the mic dropped. Maybe it's a result of using a newer version of Haxe, although Psych Engine uses 4.2.4 and doesn't have this issue. What I've done in a local build that appears to work is add the following to the GameOverSubstate.hx file, in the update function:

if (FlxG.sound.music.playing && !vibin)
          {
              FlxG.sound.music.stop();
              if (PlayState.instance.vocals != null)
                  PlayState.instance.vocals.stop();
          }

("vibin" is a bool that's set to true with the startVibin variable) I've also added the vocals.stop(); and FlxG.sound.music.stop(); lines to PlayState under each instance of the game being told to switch to the GameOverSubstate. This appears to work.

Alright, did what you told me to do, but now the game won't stop pausing, i'll see what i can do here

SilverT4 commented 2 years ago

I saw an issue like this one reported over on the FNF GameBanana. If this was posted by you, then hello, I was the one that suggested you report this here. ANYWAY.

I noticed this issue as well, I'm guessing the game doesn't listen properly when it's told to stop the music/vocals, as for me the music kept going even after the mic dropped. Maybe it's a result of using a newer version of Haxe, although Psych Engine uses 4.2.4 and doesn't have this issue. What I've done in a local build that appears to work is add the following to the GameOverSubstate.hx file, in the update function:

if (FlxG.sound.music.playing && !vibin)
            {
                FlxG.sound.music.stop();
                if (PlayState.instance.vocals != null)
                    PlayState.instance.vocals.stop();
            }

("vibin" is a bool that's set to true with the startVibin variable) I've also added the vocals.stop(); and FlxG.sound.music.stop(); lines to PlayState under each instance of the game being told to switch to the GameOverSubstate. This appears to work.

Alright, did what you told me to do, but now the game won't stop pausing, i'll see what i can do here

Ok, cool. If it's repeatedly pausing, I suggest attempting to add vibin = true; to the end of the code block where the Game Over music is played, under the startVibin = true; line and see if that changes.

SkullDollar commented 2 years ago

OK, so now command prompt is telling me that "vibin" is an "unknown identifier". We are chipping away at this issue, but we're close. For now, i'll add vibin as a boolian variable, see if that works

SkullDollar commented 2 years ago

OK, so i finally got it to work, here's what you should do if you encounter this issue: 1 - Follow this guide (https://github.com/KadeDev/Kade-Engine/blob/stable/docs/building.md) for building the game yourself. Do everything but the building part of the tutorial. 2 - On the folder where you cloned the repository, find the "source" folder. In there, find "GameOverSubstate.hx" and "PlayState.hx". 3 - Open those files in some sort of text editing program (I recommend using Notepad++) 4 - In GameOverSubstate.hx, find the line var startVibin:Bool = false;, and under it, create another line and type 'var vibin:Bool = false;'. Under it, there should be a line: 'override function update'; Copy this at it's end:

if (FlxG.sound.music.playing && !vibin) { FlxG.sound.music.stop(); if (PlayState.instance.vocals != null) PlayState.instance.vocals.stop(); }

5 - Open PlayState.hx with a text editing program. Use CTRL+F to search for every instance of GameOverSubstate being used (There should be 2 instances). After locating each instance, place this line of code under it:

vocals.stop(); FlxG.sound.music.stop();

And now, if everything has been done correctly, you may now continue with the normal building tutorial linked earlier, going into the "building" phase. Thanks so much for devin503 for helping me with this issue, without them, i would have just given up.

I will also attach the "modified" files to those that want it (Just extract it, because github doesn't like .hx files):

Modified.zip