diff options
-rw-r--r-- | actor.cpp | 19 | ||||
-rw-r--r-- | actor.h | 2 | ||||
-rw-r--r-- | object.cpp | 4 |
3 files changed, 25 insertions, 0 deletions
@@ -1392,6 +1392,25 @@ void Scumm::resetActorBgs() } } +void Actor::classChanged(int cls, bool value) +{ + switch(cls) { + case 20: // Never clip + break; + case 21: // Always clip + break; + case 22: // Ignore boxes + ignoreBoxes = value; + break; + case 29: // Y flip + break; + case 30: // X flip + break; + case 31: // ?? + break; + } +} + bool Actor::isInClass(int cls) { return _vm->getClass(number, cls); @@ -169,6 +169,8 @@ public: void setAnimVar(byte var, int value) { animVariable[var] = value; } + + void classChanged(int cls, bool value); protected: bool isInClass(int cls); diff --git a/object.cpp b/object.cpp index f27cf9be78..b0aa12687c 100644 --- a/object.cpp +++ b/object.cpp @@ -61,6 +61,10 @@ void Scumm::putClass(int obj, int cls, bool set) _classData[obj] |= (1 << (cls - 1)); else _classData[obj] &= ~(1 << (cls - 1)); + + if (1 <= obj && obj < NUM_ACTORS) { + _actors[obj].classChanged(cls, set); + } } int Scumm::getOwner(int obj) |