From 98da050c178be853be56d685fe85eae16faa324d Mon Sep 17 00:00:00 2001 From: Microkat <89645987+THEkatinamicrowave@users.noreply.github.com> Date: Fri, 2 May 2025 17:15:36 -0400 Subject: [PATCH] add fps to loadAnimatedGraphic (#626) * add fps to loadAnimatedGraphic wow and it doesn't even break old mods :0 * you'll float too hi georgie --- source/funkin/backend/utils/CoolUtil.hx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/funkin/backend/utils/CoolUtil.hx b/source/funkin/backend/utils/CoolUtil.hx index 75e7109c..f1fc14d8 100644 --- a/source/funkin/backend/utils/CoolUtil.hx +++ b/source/funkin/backend/utils/CoolUtil.hx @@ -609,11 +609,11 @@ class CoolUtil * @param spr Sprite to load the graphic for * @param path Path to the graphic */ - public static function loadAnimatedGraphic(spr:FlxSprite, path:String) { + public static function loadAnimatedGraphic(spr:FlxSprite, path:String, fps:Float = 24.0) { spr.frames = Paths.getFrames(path, true); if (spr.frames != null && spr.frames.frames != null) { - spr.animation.add("idle", [for(i in 0...spr.frames.frames.length) i], 24, true); + spr.animation.add("idle", [for(i in 0...spr.frames.frames.length) i], fps, true); spr.animation.play("idle"); }