diff --git a/source/enemy/nssnake.cpp b/source/enemy/nssnake.cpp index f0992935f..bad24234b 100644 --- a/source/enemy/nssnake.cpp +++ b/source/enemy/nssnake.cpp @@ -1018,21 +1018,6 @@ void CNpcSeaSnakeEnemy::processShot( int _frames ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/*const CRECT *CNpcSeaSnakeEnemy::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcSeaSnakeEnemy::processUserCollision( CThing *thisThing ) { } diff --git a/source/enemy/nssnake.h b/source/enemy/nssnake.h index 99629a783..ac285d581 100644 --- a/source/enemy/nssnake.h +++ b/source/enemy/nssnake.h @@ -59,7 +59,6 @@ public: virtual void shutdown(); virtual void render(); virtual int checkCollisionAgainst(CThing *_thisThing, int _frames); - //virtual CRECT const *getThinkBBox(); protected: virtual s32 getFrameShift( int _frames ); virtual bool processSensor(); diff --git a/source/enemy/nsstomp.cpp b/source/enemy/nsstomp.cpp index a5e965756..685e19b2a 100644 --- a/source/enemy/nsstomp.cpp +++ b/source/enemy/nsstomp.cpp @@ -158,21 +158,6 @@ void CNpcSkullStomperEnemy::processClose( int _frames ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/*const CRECT *CNpcSkullStomperEnemy::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcSkullStomperEnemy::collidedWith( CThing *_thisThing ) { if ( m_isActive && !m_isCaught && !m_isDying ) diff --git a/source/enemy/nsstomp.h b/source/enemy/nsstomp.h index ff9dbe73b..934785bd8 100644 --- a/source/enemy/nsstomp.h +++ b/source/enemy/nsstomp.h @@ -18,7 +18,6 @@ class CNpcSkullStomperEnemy : public CNpcEnemy { public: virtual void postInit(); - //virtual CRECT const *getThinkBBox(); protected: virtual void processEnemyCollision( CThing *thisThing ); virtual bool processSensor(); diff --git a/source/friend/fgary.cpp b/source/friend/fgary.cpp index 937801263..d7663df12 100644 --- a/source/friend/fgary.cpp +++ b/source/friend/fgary.cpp @@ -282,21 +282,6 @@ void CNpcGaryFriend::startRight() //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -const CRECT *CNpcGaryFriend::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcGaryFriend::start() { if ( !m_started ) diff --git a/source/friend/fgary.h b/source/friend/fgary.h index c23dbe68b..8104a6329 100644 --- a/source/friend/fgary.h +++ b/source/friend/fgary.h @@ -24,7 +24,7 @@ public: virtual void postInit(); virtual void think( int _frames ); virtual void setupWaypoints( sThingActor *ThisActor ); - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} DVECTOR const &getTriggerPos() {return( m_triggerPos );} void start(); void stop(); diff --git a/source/hazard/hbarrel.cpp b/source/hazard/hbarrel.cpp index eb089b8bf..de66bfd99 100644 --- a/source/hazard/hbarrel.cpp +++ b/source/hazard/hbarrel.cpp @@ -152,18 +152,3 @@ void CNpcBarrelHazard::render() m_modelGfx->Render(renderPos,&rotation,&scale); } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcBarrelHazard::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/hazard/hbarrel.h b/source/hazard/hbarrel.h index ecbc2f3d1..fa1c0f2b3 100644 --- a/source/hazard/hbarrel.h +++ b/source/hazard/hbarrel.h @@ -23,7 +23,6 @@ class CNpcBarrelHazard : public CNpcHazard public: void init(); void render(); - //virtual CRECT const *getThinkBBox(); protected: void processMovement( int _frames ); diff --git a/source/hazard/hbbarrel.cpp b/source/hazard/hbbarrel.cpp index 29b49c0cc..84c552f0d 100644 --- a/source/hazard/hbbarrel.cpp +++ b/source/hazard/hbbarrel.cpp @@ -198,21 +198,6 @@ void CNpcBouncingBarrelHazard::render() //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/*const CRECT *CNpcBouncingBarrelHazard::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcBouncingBarrelHazard::collidedWith( CThing *_thisThing ) { if ( m_isActive ) diff --git a/source/hazard/hbbarrel.h b/source/hazard/hbbarrel.h index f92e8fd5e..06780bc87 100644 --- a/source/hazard/hbbarrel.h +++ b/source/hazard/hbbarrel.h @@ -23,7 +23,6 @@ class CNpcBouncingBarrelHazard : public CNpcHazard public: void init(); void render(); - //virtual CRECT const *getThinkBBox(); protected: void processMovement( int _frames ); virtual void collidedWith(CThing *_thisThing); diff --git a/source/hazard/hbwheel.cpp b/source/hazard/hbwheel.cpp index 3158fdc9f..03cea3e8c 100644 --- a/source/hazard/hbwheel.cpp +++ b/source/hazard/hbwheel.cpp @@ -76,18 +76,3 @@ void CNpcBigWheelHazard::collidedWith( CThing *_thisThing ) { // do not collide } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -const CRECT *CNpcBigWheelHazard::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} \ No newline at end of file diff --git a/source/hazard/hbwheel.h b/source/hazard/hbwheel.h index bb6944704..21fa7dafd 100644 --- a/source/hazard/hbwheel.h +++ b/source/hazard/hbwheel.h @@ -23,7 +23,7 @@ class CNpcBigWheelHazard : public CNpcHazard public: void init(); virtual void render(); - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} protected: void processMovement( int _frames ); virtual void collidedWith(CThing *_thisThing); diff --git a/source/hazard/hdbarrel.cpp b/source/hazard/hdbarrel.cpp index 4fffa817e..dd6f99227 100644 --- a/source/hazard/hdbarrel.cpp +++ b/source/hazard/hdbarrel.cpp @@ -178,18 +178,3 @@ void CNpcDualPlatformBarrelHazard::render() m_modelGfx->Render(renderPos,&rotation,&scale); } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcDualPlatformBarrelHazard::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/hazard/hdbarrel.h b/source/hazard/hdbarrel.h index 6f50cc67f..80d1ecfe4 100644 --- a/source/hazard/hdbarrel.h +++ b/source/hazard/hdbarrel.h @@ -23,7 +23,6 @@ class CNpcDualPlatformBarrelHazard : public CNpcHazard public: void init(); void render(); - //virtual CRECT const *getThinkBBox(); protected: void processMovement( int _frames ); diff --git a/source/hazard/hfalling.cpp b/source/hazard/hfalling.cpp index 8db555161..27d6c4444 100644 --- a/source/hazard/hfalling.cpp +++ b/source/hazard/hfalling.cpp @@ -225,18 +225,6 @@ void CNpcFallingHazard::collidedWith( CThing *_thisThing ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/*const CRECT *CNpcFallingHazard::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.y2 = thinkBBox.YMin + 1; - - return &objThinkBox; -}*/ - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcFallingHazard::setWaypoints( sThingHazard *ThisHazard ) { int pointNum; diff --git a/source/hazard/hfalling.h b/source/hazard/hfalling.h index 363082e30..473d59949 100644 --- a/source/hazard/hfalling.h +++ b/source/hazard/hfalling.h @@ -22,7 +22,6 @@ class CNpcFallingHazard : public CNpcHazard { public: void init(); - //virtual CRECT const *getThinkBBox(); virtual void setWaypoints( sThingHazard *ThisHazard ); void render(); protected: diff --git a/source/hazard/hrrock.cpp b/source/hazard/hrrock.cpp index 42b8f4c2f..5e6cf4670 100644 --- a/source/hazard/hrrock.cpp +++ b/source/hazard/hrrock.cpp @@ -199,18 +199,3 @@ void CNpcRollingRockHazard::render() m_modelGfx->Render(renderPos,&rotation,&scale); } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcRollingRockHazard::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/hazard/hrrock.h b/source/hazard/hrrock.h index 0b0cf4234..c41c0a4b9 100644 --- a/source/hazard/hrrock.h +++ b/source/hazard/hrrock.h @@ -23,7 +23,6 @@ class CNpcRollingRockHazard : public CNpcHazard public: void init(); void render(); - //virtual CRECT const *getThinkBBox(); protected: void processMovement( int _frames ); diff --git a/source/hazard/hspikes.cpp b/source/hazard/hspikes.cpp index 651116412..879386364 100644 --- a/source/hazard/hspikes.cpp +++ b/source/hazard/hspikes.cpp @@ -95,21 +95,6 @@ void CNpcSpikesHazard::processMovement( int _frames ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -const CRECT *CNpcSpikesHazard::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcSpikesHazard::processTimer( int _frames ) { if ( m_timer > 0 ) diff --git a/source/hazard/hspikes.h b/source/hazard/hspikes.h index bf4b85270..2fa9a801c 100644 --- a/source/hazard/hspikes.h +++ b/source/hazard/hspikes.h @@ -22,7 +22,7 @@ class CNpcSpikesHazard : public CNpcHazard { public: void init(); - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} protected: virtual void processTimer( int _frames ); void processMovement( int _frames ); diff --git a/source/platform/pbgeyser.cpp b/source/platform/pbgeyser.cpp index e374c0874..e098a372e 100644 --- a/source/platform/pbgeyser.cpp +++ b/source/platform/pbgeyser.cpp @@ -89,18 +89,3 @@ void CNpcGeyserPlatformGenerator::think( int _frames ) newPlatform->postInit(); } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcGeyserPlatformGenerator::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/platform/pbgeyser.h b/source/platform/pbgeyser.h index 178551f30..bd05590cf 100644 --- a/source/platform/pbgeyser.h +++ b/source/platform/pbgeyser.h @@ -23,7 +23,6 @@ class CNpcGeyserPlatformGenerator : public CNpcPlatform public: void setTargetType( NPC_PLATFORM_UNIT_TYPE targetType ) {m_targetType = targetType;} virtual void render(); - //virtual CRECT const *getThinkBBox(); protected: virtual void think( int _frames ); virtual void collidedWith(CThing *_thisThing); diff --git a/source/platform/pbubble.cpp b/source/platform/pbubble.cpp index 05cbbdbf1..ba71fad21 100644 --- a/source/platform/pbubble.cpp +++ b/source/platform/pbubble.cpp @@ -128,18 +128,3 @@ void CNpcBubblePlatform::processLifetime( int _frames ) } } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcBubblePlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/platform/pbubble.h b/source/platform/pbubble.h index e39451f2e..01bbfd357 100644 --- a/source/platform/pbubble.h +++ b/source/platform/pbubble.h @@ -23,7 +23,6 @@ class CNpcBubblePlatform : public CNpcPlatform public: virtual void render(); virtual void postInit(); - //virtual CRECT const *getThinkBBox(); protected: virtual void processLifetime( int _frames ); virtual void processMovement( int _frames ); diff --git a/source/platform/pbwheel.cpp b/source/platform/pbwheel.cpp index 26cf03b71..ed53db808 100644 --- a/source/platform/pbwheel.cpp +++ b/source/platform/pbwheel.cpp @@ -98,21 +98,6 @@ void CNpcBigWheelPlatform::setWaypoints( sThingPlatform *ThisPlatform ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -const CRECT *CNpcBigWheelPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - int CNpcBigWheelPlatform::getHeightFromPlatformAtPosition(int _x,int _y, int offsetX, int offsetY) { DVECTOR top; diff --git a/source/platform/pbwheel.h b/source/platform/pbwheel.h index 969dcb40b..3c5759e4e 100644 --- a/source/platform/pbwheel.h +++ b/source/platform/pbwheel.h @@ -21,7 +21,7 @@ class CNpcBigWheelPlatform : public CNpcPlatform { public: - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} virtual void postInit(); virtual int getHeightFromPlatformAtPosition(int _x,int _y, int offsetX = 0, int offsetY = 0); protected: diff --git a/source/platform/pconveyr.cpp b/source/platform/pconveyr.cpp index e07f5361d..7b49d912e 100644 --- a/source/platform/pconveyr.cpp +++ b/source/platform/pconveyr.cpp @@ -87,21 +87,6 @@ void CNpcConveyorPlatformGenerator::think( int _frames ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/*const CRECT *CNpcConveyorPlatformGenerator::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcConveyorPlatform::postInit() { CNpcPlatform::postInit(); @@ -183,21 +168,6 @@ void CNpcConveyorPlatform::processMovement( int _frames ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/*const CRECT *CNpcConveyorPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcConveyorPlatform::collidedWith( CThing *_thisThing ) { switch(_thisThing->getThingType()) diff --git a/source/platform/pconveyr.h b/source/platform/pconveyr.h index 4325b94d3..bec62ad46 100644 --- a/source/platform/pconveyr.h +++ b/source/platform/pconveyr.h @@ -22,7 +22,6 @@ class CNpcConveyorPlatform : public CNpcPlatform { public: virtual void postInit(); - //virtual CRECT const *getThinkBBox(); virtual void render(); virtual int checkCollisionAgainst(CThing *_thisThing, int _frames); protected: @@ -37,7 +36,6 @@ class CNpcConveyorPlatformGenerator : public CNpcPlatform { public: virtual void render(); - //virtual CRECT const *getThinkBBox(); protected: virtual void think( int _frames ); virtual void collidedWith(CThing *_thisThing); diff --git a/source/platform/pdrop.cpp b/source/platform/pdrop.cpp index 81354d9f4..d93c28d56 100644 --- a/source/platform/pdrop.cpp +++ b/source/platform/pdrop.cpp @@ -35,18 +35,3 @@ void CNpcDropPlatform::processMovement( int _frames ) Pos.vy += moveY; } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcDropPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/platform/pdrop.h b/source/platform/pdrop.h index a18d058d3..5d9b56c95 100644 --- a/source/platform/pdrop.h +++ b/source/platform/pdrop.h @@ -20,8 +20,6 @@ class CNpcDropPlatform : public CNpcPlatform { -//public: - //virtual CRECT const *getThinkBBox(); protected: virtual void processMovement( int _frames ); }; diff --git a/source/platform/pdual.cpp b/source/platform/pdual.cpp index e5a4b8134..69d086beb 100644 --- a/source/platform/pdual.cpp +++ b/source/platform/pdual.cpp @@ -336,21 +336,6 @@ void CNpcDualPlatform::render() //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/*const CRECT *CNpcDualPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcDualPlatform::collidedWith( CThing *_thisThing ) { switch(_thisThing->getThingType()) diff --git a/source/platform/pdual.h b/source/platform/pdual.h index 7c34bbe42..c7594d20f 100644 --- a/source/platform/pdual.h +++ b/source/platform/pdual.h @@ -29,7 +29,6 @@ public: DVECTOR getLineBase() {return( m_lineBase );} virtual void render(); void setThinkArea( CRECT &newArea ); - //virtual CRECT const *getThinkBBox(); protected: virtual void setWaypoints( sThingPlatform *ThisPlatform ); virtual void processMovement( int _frames ); diff --git a/source/platform/pfallnor.cpp b/source/platform/pfallnor.cpp index 8c9684ad4..5f72afb0a 100644 --- a/source/platform/pfallnor.cpp +++ b/source/platform/pfallnor.cpp @@ -124,21 +124,6 @@ void CNpcFallingNoRespawnPlatform::processMovement( int _frames ) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -const CRECT *CNpcFallingNoRespawnPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - void CNpcFallingNoRespawnPlatform::render() { if ( m_isActive ) diff --git a/source/platform/pfallnor.h b/source/platform/pfallnor.h index 089df9029..0d97d9f2d 100644 --- a/source/platform/pfallnor.h +++ b/source/platform/pfallnor.h @@ -22,7 +22,7 @@ class CNpcFallingNoRespawnPlatform : public CNpcPlatform { public: virtual void postInit(); - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} virtual int checkCollisionAgainst(CThing *_thisThing, int _frames); protected: virtual void render(); diff --git a/source/platform/pfgen.cpp b/source/platform/pfgen.cpp index 48f040cd9..7efbd5aae 100644 --- a/source/platform/pfgen.cpp +++ b/source/platform/pfgen.cpp @@ -97,18 +97,3 @@ void CNpcFallingPlatformGenerator::think( int _frames ) newPlatform->postInit(); } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -const CRECT *CNpcFallingPlatformGenerator::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} \ No newline at end of file diff --git a/source/platform/pfgen.h b/source/platform/pfgen.h index 5a102a73c..ecb28e7be 100644 --- a/source/platform/pfgen.h +++ b/source/platform/pfgen.h @@ -23,7 +23,7 @@ class CNpcFallingPlatformGenerator : public CNpcPlatform public: void setTargetType( NPC_PLATFORM_UNIT_TYPE targetType ) {m_targetType = targetType;} virtual void render(); - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} protected: virtual void think( int _frames ); virtual void collidedWith(CThing *_thisThing); diff --git a/source/platform/pjellfsh.cpp b/source/platform/pjellfsh.cpp index 6df59b2fb..8114ab7a8 100644 --- a/source/platform/pjellfsh.cpp +++ b/source/platform/pjellfsh.cpp @@ -140,18 +140,3 @@ void CNpcJellyfishPlatform::think( int _frames ) CNpcLinearPlatform::think( _frames ); } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcJellyfishPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/platform/pjellfsh.h b/source/platform/pjellfsh.h index 30a25aac7..60c6e52fd 100644 --- a/source/platform/pjellfsh.h +++ b/source/platform/pjellfsh.h @@ -23,7 +23,6 @@ class CNpcJellyfishPlatform : public CNpcLinearPlatform public: virtual void postInit(); virtual void think( int _frames ); - //virtual CRECT const *getThinkBBox(); protected: virtual void collidedWith(CThing *_thisThing); diff --git a/source/platform/plantern.cpp b/source/platform/plantern.cpp index 32aac4fb9..1936ad2b1 100644 --- a/source/platform/plantern.cpp +++ b/source/platform/plantern.cpp @@ -118,18 +118,3 @@ void CNpcLanternPlatform::processMovement( int _frames ) Pos.vx = m_base.vx + ( ( m_length * rcos( m_heading + m_extension ) ) >> 12 ); Pos.vy = m_base.vy + ( ( m_length * rsin( m_heading + m_extension ) ) >> 12 ); } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -const CRECT *CNpcLanternPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} diff --git a/source/platform/plantern.h b/source/platform/plantern.h index d4d558aa3..8f03715df 100644 --- a/source/platform/plantern.h +++ b/source/platform/plantern.h @@ -22,7 +22,7 @@ class CNpcLanternPlatform : public CNpcPlatform { public: virtual void postInit(); - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} protected: virtual void setWaypoints( sThingPlatform *ThisPlatform ); virtual void processMovement( int _frames ); diff --git a/source/platform/plinear.cpp b/source/platform/plinear.cpp index 38130fb01..0c2d933c0 100644 --- a/source/platform/plinear.cpp +++ b/source/platform/plinear.cpp @@ -136,18 +136,3 @@ void CNpcLinearPlatform::processMovement( int _frames ) Pos.vx += moveX; Pos.vy += moveY; } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcLinearPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/platform/plinear.h b/source/platform/plinear.h index b77cd8faf..300c9778f 100644 --- a/source/platform/plinear.h +++ b/source/platform/plinear.h @@ -22,7 +22,6 @@ class CNpcLinearPlatform : public CNpcPlatform { public: virtual void postInit(); - //virtual CRECT const *getThinkBBox(); protected: virtual void processMovement( int _frames ); }; diff --git a/source/platform/ppendulm.cpp b/source/platform/ppendulm.cpp index 06a81ed2a..d46fac5d4 100644 --- a/source/platform/ppendulm.cpp +++ b/source/platform/ppendulm.cpp @@ -196,15 +196,3 @@ void CNpcPendulumPlatform::render() } } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcPendulumPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.y1 = thinkBBox.YMax - 1; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/platform/ppendulm.h b/source/platform/ppendulm.h index 9a213deff..a6b54f958 100644 --- a/source/platform/ppendulm.h +++ b/source/platform/ppendulm.h @@ -23,7 +23,6 @@ class CNpcPendulumPlatform : public CNpcPlatform public: virtual void postInit(); virtual void render(); - //virtual CRECT const *getThinkBBox(); protected: virtual void setWaypoints( sThingPlatform *ThisPlatform ); virtual void processMovement( int _frames ); diff --git a/source/platform/praft.cpp b/source/platform/praft.cpp index 928f9a022..abce7903f 100644 --- a/source/platform/praft.cpp +++ b/source/platform/praft.cpp @@ -212,18 +212,3 @@ void CNpcRaftPlatform::render() } } } - -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/*const CRECT *CNpcRaftPlatform::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -}*/ \ No newline at end of file diff --git a/source/platform/praft.h b/source/platform/praft.h index 4b88a2027..7d0e66ee9 100644 --- a/source/platform/praft.h +++ b/source/platform/praft.h @@ -23,7 +23,6 @@ class CNpcRaftPlatform : public CNpcPlatform public: virtual void postInit(); virtual void render(); - //virtual CRECT const *getThinkBBox(); protected: virtual void processMovement( int _frames ); diff --git a/source/triggers/tgbowl.cpp b/source/triggers/tgbowl.cpp index 520d4d7f7..6ac12b991 100644 --- a/source/triggers/tgbowl.cpp +++ b/source/triggers/tgbowl.cpp @@ -68,20 +68,5 @@ void CGaryBowlTrigger::collidedWith(CThing *_thisThing) } } -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -const CRECT *CGaryBowlTrigger::getThinkBBox() -{ - CRECT objThinkBox = getCollisionArea(); - - sBBox &thinkBBox = CThingManager::getThinkBBox(); - objThinkBox.x1 = thinkBBox.XMin; - objThinkBox.x2 = thinkBBox.XMax; - objThinkBox.y1 = thinkBBox.YMin; - objThinkBox.y2 = thinkBBox.YMax; - - return &objThinkBox; -} - /*=========================================================================== end */ diff --git a/source/triggers/tgbowl.h b/source/triggers/tgbowl.h index 146483158..17b848771 100644 --- a/source/triggers/tgbowl.h +++ b/source/triggers/tgbowl.h @@ -37,7 +37,7 @@ class CGaryBowlTrigger : public CTrigger { public: - virtual CRECT const *getThinkBBox(); + bool alwaysThink() {return(true);} protected: virtual void collidedWith(CThing *_thisThing); };