void Planet::updateCurrent(sf::Time dt, CommandQueue& commands) { if (isDestroyed()) { mIsMarkedForRemoval = true; return; } updateMovementPattern(dt); mSprite.rotate(15 * dt.asSeconds()); Entity::updateCurrent(dt, commands); }
void Aircraft::updateCurrent(sf::Time dt, CommandQueue& commands) { if (isDestroyed()) { checkPickupDrop(commands); mIsMarkedForRemoval = true; return; } checkProjectileLaunch(dt, commands); updateMovementPattern(dt); Entity::updateCurrent(dt, commands); updateText(); }
void Aircraft::updateCurrent(sf::Time dt, CommandQueue& commands) { // Entity has been destroyed: Possibly drop pickup, mark for removal if (isDestroyed()) { checkPickupDrop(commands); mIsMarkedForRemoval = true; return; } // Check if bullets or missiles are fired checkProjectileLaunch(dt, commands); // Update enemy movement pattern; apply velocity updateMovementPattern(dt); Entity::updateCurrent(dt, commands); // Update texts updateTexts(); }