Merge pull request from FunkinCrew/bugfix/hud-hiding

Several tiny bug fixes
This commit is contained in:
Cameron Taylor 2024-07-19 19:10:28 -04:00 committed by GitHub
commit bfa0bafc6f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 8 additions and 8 deletions
source/funkin

View file

@ -251,6 +251,10 @@ class PolymodHandler
// Lib.load() can load malicious DLLs
Polymod.blacklistImport('cpp.Lib');
// `Unserializer`
// Unserializerr.DEFAULT_RESOLVER.resolveClass() can access blacklisted packages
Polymod.blacklistImport('Unserializer');
// `polymod.*`
// You can probably unblacklist a module
for (cls in ClassMacro.listClassesInPackage('polymod'))

View file

@ -578,7 +578,6 @@ class PlayState extends MusicBeatSubState
// TODO: Refactor or document
var generatedMusic:Bool = false;
var perfectMode:Bool = false;
static final BACKGROUND_COLOR:FlxColor = FlxColor.BLACK;
@ -2535,12 +2534,6 @@ class PlayState extends MusicBeatSubState
*/
function debugKeyShit():Void
{
#if !debug
perfectMode = false;
#else
if (FlxG.keys.justPressed.H) camHUD.visible = !camHUD.visible;
#end
#if CHART_EDITOR_SUPPORTED
// Open the stage editor overlaying the current state.
if (controls.DEBUG_STAGE)
@ -2572,6 +2565,9 @@ class PlayState extends MusicBeatSubState
#end
#if (debug || FORCE_DEBUG_VERSION)
// H: Hide the HUD.
if (FlxG.keys.justPressed.H) camHUD.visible = !camHUD.visible;
// 1: End the song immediately.
if (FlxG.keys.justPressed.ONE) endSong(true);

View file

@ -277,7 +277,7 @@ class Song implements IPlayStateScriptedClass implements IRegistryEntry<SongMeta
// If there are no difficulties in the metadata, there's a problem.
if (metadata.playData.difficulties.length == 0)
{
throw 'Song $id has no difficulties listed in metadata!';
trace('[WARN] Song $id has no difficulties listed in metadata!');
}
// There may be more difficulties in the chart file than in the metadata,