mirror of
https://github.com/FunkinCrew/Funkin.git
synced 2024-11-23 08:07:54 -05:00
40 lines
714 B
Haxe
40 lines
714 B
Haxe
package;
|
|
|
|
import flixel.FlxG;
|
|
import flixel.FlxSprite;
|
|
import flixel.graphics.frames.FlxAtlasFrames;
|
|
import flixel.util.FlxTimer;
|
|
|
|
using StringTools;
|
|
|
|
class Boyfriend extends Character
|
|
{
|
|
public var stunned:Bool = false;
|
|
|
|
public function new(x:Float, y:Float)
|
|
{
|
|
super(x, y);
|
|
}
|
|
|
|
override function update(elapsed:Float)
|
|
{
|
|
if (animation.curAnim.name.startsWith('sing'))
|
|
{
|
|
holdTimer += elapsed;
|
|
}
|
|
else
|
|
holdTimer = 0;
|
|
|
|
if (animation.curAnim.name.endsWith('miss') && animation.curAnim.finished && !debugMode)
|
|
{
|
|
playAnim('idle', true, false, 10);
|
|
}
|
|
|
|
if (animation.curAnim.name == 'firstDeath' && animation.curAnim.finished)
|
|
{
|
|
playAnim('deathLoop');
|
|
}
|
|
|
|
super.update(elapsed);
|
|
}
|
|
}
|