You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
529 B
C++

#include "classicnotedyingstate.h"
#include "../classicnote.h"
#include "../classicsprite.h"
auto ClassicNoteDyingState::value() const -> Value
{
return Value::DYING;
}
auto ClassicNoteDyingState::update(const ClassicNote* note, const microsec& offset) -> Value
{
(void) offset;
const auto& sprite = note->sprite();
sprite->update();
if (sprite->isDead())
return Value::NONE;
return value();
}
void ClassicNoteDyingState::onEntering(const ClassicNote* note)
{
note->sprite()->pulse();
}