1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2025-11-25 13:45:49 +00:00

Prepare the FlxAnimate bizz

This commit is contained in:
CheemsAndFriends 2024-08-19 13:40:58 +02:00
parent eb5bf449a4
commit 4dad17d241

View file

@ -22,28 +22,14 @@ class FlxAnimateTest extends MusicBeatState
{
super.create();
sprite = new FlxAtlasSprite(0, 0, 'shared:assets/shared/images/characters/tankman');
add(sprite);
sprite = new FlxAtlasSprite(0, 0, 'assets/images/freeplay/freeplay-boyfriend'); // I suppose a specific atlas to test should go in here
sprite.playAnimation('idle');
add(sprite);
sprite.anim.play("Boyfriend DJ");
}
public override function update(elapsed:Float):Void
{
super.update(elapsed);
if (FlxG.keys.justPressed.SPACE) sprite.playAnimation('idle');
if (FlxG.keys.justPressed.W) sprite.playAnimation('singUP');
if (FlxG.keys.justPressed.A) sprite.playAnimation('singLEFT');
if (FlxG.keys.justPressed.S) sprite.playAnimation('singDOWN');
if (FlxG.keys.justPressed.D) sprite.playAnimation('singRIGHT');
if (FlxG.keys.justPressed.J) sprite.playAnimation('hehPrettyGood');
if (FlxG.keys.justPressed.K) sprite.playAnimation('ugh');
}
}