for opponent

This commit is contained in:
Spel0 2021-08-13 19:43:04 +03:00
parent 91a6b772ff
commit fac055c9a1
2 changed files with 6 additions and 3 deletions

View File

@ -452,7 +452,7 @@ class Character extends FlxSprite
/**
* FOR GF DANCING SHIT
*/
public function dance(forced:Bool = false)
public function dance(forced:Bool = false, altAnim:Bool = false)
{
if (!debugMode)
{
@ -476,6 +476,9 @@ class Character extends FlxSprite
else
playAnim('danceLeft');
default:
if (altAnim && animation.getByName('idle-alt') != null)
playAnim('idle-alt', forced);
else
playAnim('idle', forced);
}
}

View File

@ -4594,7 +4594,7 @@ class PlayState extends MusicBeatState
// Dad doesnt interupt his own notes
if ((!dad.animation.curAnim.name.startsWith("sing")) && dad.curCharacter != 'gf')
if ((curBeat % idleBeat == 0 || !idleToBeat) || dad.curCharacter == "spooky")
dad.dance(idleToBeat);
dad.dance(idleToBeat, SONG.notes[Math.floor(curStep / 16)].altAnim);
}
// FlxG.log.add('change bpm' + SONG.notes[Std.int(curStep / 16)].changeBPM);
wiggleShit.update(Conductor.crochet);