1
0
mirror of https://github.com/XProger/OpenLara.git synced 2025-07-31 02:10:35 +02:00
This commit is contained in:
XProger
2019-03-20 01:30:20 +03:00
parent fe431c687c
commit 46a15236e7

View File

@@ -1382,7 +1382,13 @@ struct MovingObject : Controller {
struct CentaurStatue : Controller { struct CentaurStatue : Controller {
CentaurStatue(IGame *game, int entity) : Controller(game, entity) {} CentaurStatue(IGame *game, int entity) : Controller(game, entity) {
flags.unused = false;
}
virtual bool activate() {
return (flags.unused ? false : Controller::activate());
}
virtual void update() { virtual void update() {
if (explodeMask) { if (explodeMask) {
@@ -1393,6 +1399,7 @@ struct CentaurStatue : Controller {
} }
if ((pos - game->getLara(pos)->pos).length() < CENTAUR_STATUE_RANGE) { if ((pos - game->getLara(pos)->pos).length() < CENTAUR_STATUE_RANGE) {
flags.unused = true;
explode(0xFFFFFFFF, 0.0f); explode(0xFFFFFFFF, 0.0f);
game->playSound(TR::SND_EXPLOSION, pos, Sound::PAN); game->playSound(TR::SND_EXPLOSION, pos, Sound::PAN);
Controller *enemy = game->addEntity(TR::Entity::ENEMY_CENTAUR, getRoomIndex(), pos, angle.y); Controller *enemy = game->addEntity(TR::Entity::ENEMY_CENTAUR, getRoomIndex(), pos, angle.y);