From c294c708170f528985933965f3320521dcbf1c5e Mon Sep 17 00:00:00 2001 From: TheZoroForce240 <86524550+TheZoroForce240@users.noreply.github.com> Date: Tue, 20 Aug 2024 20:50:12 +0100 Subject: [PATCH] fix video cutscenes (#372) --- source/funkin/game/cutscenes/VideoCutscene.hx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/source/funkin/game/cutscenes/VideoCutscene.hx b/source/funkin/game/cutscenes/VideoCutscene.hx index 8e290631..de485450 100644 --- a/source/funkin/game/cutscenes/VideoCutscene.hx +++ b/source/funkin/game/cutscenes/VideoCutscene.hx @@ -56,8 +56,13 @@ class VideoCutscene extends Cutscene { parseSubtitles(); video = new FlxVideo(); - video.onEndReached.add(video.dispose); + video.onEndReached.add(function() + { + video.dispose(); + FlxG.removeChild(video); + }); video.onEndReached.add(close); + FlxG.addChildBelowMouse(video); //cover = new FlxSprite(0, FlxG.height * 0.85).makeSolid(FlxG.width + 50, FlxG.height + 50, 0xFF000000); //cover.scrollFactor.set(0, 0);