Verwex / Funkin-Mic-d-Up-SC

A mod to Friday Night Funkin' called FNF: Mic'd Up, previously named EX Replayability.
Other
76 stars 111 forks source link

Bug Report: "Spam Prevention" game crash #70

Closed Spel0 closed 3 years ago

Spel0 commented 3 years ago

How to reproduce: turn "Spam Prevention" option to true and load any song. Two problems: 1) Spam Prevention doesn't work at all(you can still spam, won't count as a miss and miss animation doesn't play) 2) When notes that you suppose to hit comes and you hit it, the game just crashes

Was tested on windows 10, 64 bit system.

Video of the bug: https://www.youtube.com/watch?v=G9GdU7N5XEU

Spel0 commented 3 years ago

Debug info image

Salted-Beef commented 3 years ago

I'm having the same issue. I originally thought it was because I was using a custom skin, but it doesn't seem to be the case. I really hope this gets fixed.

ghost commented 3 years ago

I believe it's because PlayState.hx (line 4505-4518) is borked

if (dontCheck && possibleNotes.length > 0 || _variables.spamPrevention && possibleNotes.length > 0)
{
    if (mashViolations > 4 || _variables.spamPrevention)
    {
        trace('mash violations ' + mashViolations);
        scoreTxt.color = FlxColor.RED;
        for (shit in 0...pressArray.length)
            if (pressArray[shit])
                noteMiss(shit);
    }
    else
        mashViolations++;
    }
}

For some reason, it checks if you have spam prevention enabled, and if you do, it checks if you mashed 4 times... or have spam prevention on. KadeDev did make a pull request, #35 to fix the old input, and that got merged, but i assume somewhere along the way they decided to also check if spam prevention is enabled, but instead of using the and (&&) operator, they used the or (||) by accident.

haya3218 commented 3 years ago

Will be fixed