class CoolUtil
package funkin.utils
Static methods
staticgetColorFromDynamic(c:Dynamic):Null<FlxColor>
Tries to get a color from a Dynamic variable.
Parameters:
c |
|
|---|
Returns:
The result color, or null if invalid.
staticinlinegetFPSRatio(ratio:Float):Float
Modifies a lerp ratio based on current FPS to keep a stable speed on higher framerate.
Parameters:
ratio | Ratio |
|---|
Returns:
FPS-Modified Ratio
staticgetMacroAbstractClass(className:String):Class<Dynamic>
Gets the macro class created by hscript-improved for an abstract / enum
staticinlinelerpColor(color1:FlxColor, color2:FlxColor, ratio:Float, fpsSensitive:Bool = false):FlxColor
Lerps from color1 into color2 (Shortcut to FlxColor.interpolate)
Parameters:
color1 | Color 1 |
|---|---|
color2 | Color 2 |
ratio | Ratio |
fpsSensitive | Whenever the ratio should be fps sensitive (adapted when game is running at 120 instead of 60) |
staticloadFrames(path:String, Unique:Bool = false, ?Key:String, SkipAtlasCheck:Bool = false):FlxFramesCollection
staticloadSong(name:String, difficulty:String = "normal", opponentMode:Bool = false, coopMode:Bool = false):Void
staticplayMenuSFX(menuSFX:CoolSfx = SCROLL, volume:Float = 1):Void
Plays a specified Menu SFX.
Parameters:
menuSFX | Menu SFX to play |
|---|---|
volume | At which volume it should play |