Commit 6eba5cb3 authored by Gerhard Stein's avatar Gerhard Stein

More Cleanups

parent f81a0c4d
......@@ -38,7 +38,6 @@ m_Player(Player)
desty = 0;
inhibitfall = 1;
canbezapped = 0;
needinit = 0;
for(size_t i=0;i<=NESSIETRAILLEN;i++)
{
......
......@@ -24,7 +24,6 @@ m_Player(Player)
blockedl = blockedr = false;
inhibitfall = 1;
needinit = 0;
canbezapped = 1;
SetAllCanSupportPlayer(1);
}
......
......@@ -25,7 +25,6 @@ CPlatform(p_map, x, y, Player)
blockedu = false;
blockedd = true;
inhibitfall = 1;
needinit = 0;
canbezapped = 1;
SetAllCanSupportPlayer(1);
......
......@@ -20,7 +20,6 @@ CSpriteObject(p_map, x, y, OBJ_GOTPOINTS)
inhibitfall = true;
solid = false;
honorPriority = false;
needinit = 0;
}
......
......@@ -17,7 +17,6 @@ CSpriteObject(p_map, x, y, OBJ_ROPE)
canbezapped = 1;
inhibitfall = true;
sprite = OBJ_ROPE_DEFSPRITE;
needinit = false;
solid = false;
droptimer = 0;
}
......
......@@ -37,7 +37,6 @@ m_Player(Player)
walkframe = 0;
animtimer = 0;
inhibitfall = true;
needinit = false;
canbezapped = true;
performCollisions();
......@@ -349,7 +348,6 @@ void CScrub::fall()
if (blockedd)
{
inhibitfall = true;
needinit = false;
canbezapped = true;
performCollisions();
......
......@@ -91,7 +91,6 @@ m_Object(Object)
dir = UP;
state = LEG_GO;
inhibitfall = 1;
needinit = false;
break;
case SE_MORTIMER_SPARK:
state = MSPARK_IDLE;
......@@ -296,7 +295,6 @@ void CSectorEffector::se_mortimer_spark()
if (SE.m_index!=m_index)
{ // other sparks still exist
setype = SE_MORTIMER_RANDOMZAPS;
needinit = true;
return;
}
}
......@@ -338,7 +336,6 @@ void CSectorEffector::se_mortimer_spark()
CRay *newobject = new CRay(mp_Map, ((mx<<4)+4)<<STC, my<<4<<STC, DOWN);
newobject->state = CRay::RAY_STATE_SETZAPZOT;
newobject->inhibitfall = true;
newobject->needinit = false;
m_Object.push_back(newobject);
}
......@@ -350,7 +347,6 @@ void CSectorEffector::se_mortimer_spark()
CRay *newobject = new CRay(mp_Map, ((mx<<4)+4)<<STC, my<<4<<STC, DOWN);
newobject->state = CRay::RAY_STATE_SETZAPZOT;
newobject->inhibitfall = true;
newobject->needinit = false;
m_Object.push_back(newobject);
}
......@@ -455,7 +451,6 @@ void CSectorEffector::se_mortimer_heart()
CRay *newobject = new CRay(mp_Map, ((x<<4)+4)<<STC, my<<4<<STC, DOWN);
newobject->state = CRay::RAY_STATE_SETZAPZOT;
newobject->inhibitfall = true;
newobject->needinit = false;
m_Object.push_back(newobject);
}
......@@ -492,7 +487,6 @@ void CSectorEffector::se_mortimer_zapsup()
CRay *newobject = new CRay(mp_Map, ((x<<4)+4)<<STC, my<<4<<STC, DOWN);
newobject->state = CRay::RAY_STATE_SETZAPZOT;
newobject->inhibitfall = true;
newobject->needinit = false;
m_Object.push_back(newobject);
if (destroytiles)
......@@ -728,7 +722,6 @@ void CSectorEffector::se_mortimer_randomzaps()
CRay *newobject = new CRay(mp_Map,x<<CSF, y<<CSF, RIGHT );
newobject->state = CRay::RAY_STATE_SETZAPZOT;
newobject->inhibitfall = true;
newobject->needinit = false;
m_Object.push_back(newobject);
timer = TIME_BETWEEN_ZAPS;
......
......@@ -32,12 +32,14 @@ const int EARTHCHUNK_SMALL_UP = 68;
const int EARTHCHUNK_SMALL_DN = 70;
CTantalusRay::CTantalusRay(std::list< SmartPointer<CMessageBoxVort> > &messageBoxes,
const SmartPointer<CMap> &pMap, std::vector<CSpriteObject*> &vect_obj, CSpriteObjectAI &objectai) :
const SmartPointer<CMap> &pMap,
std::vector<CSpriteObject*> &vect_obj,
SmartPointer<CSpriteObjectAI> &objectai) :
CFinale(messageBoxes, pMap, vect_obj),
m_mustsetup(true),
m_alternate_sprite(0),
mp_MessageBox(new CMessageBoxVort("Uh-Oh")),
m_objectai(objectai),
mObjectAI(objectai),
m_timer(0),
mp_Bitmap(g_pGfxEngine->getBitmap("GAMEOVER")),
mp_process(&CTantalusRay::shootray)
......@@ -61,7 +63,7 @@ void CTantalusRay::process()
{
(this->*mp_process)();
m_objectai.process();
mObjectAI->process();
}
}
......
......@@ -20,7 +20,9 @@ class CTantalusRay : public CFinale
{
public:
CTantalusRay(std::list< SmartPointer<CMessageBoxVort> > &messageBoxes,
const SmartPointer<CMap> &pMap, std::vector<CSpriteObject*> &vect_obj, CSpriteObjectAI &objectai);
const SmartPointer<CMap> &pMap,
std::vector<CSpriteObject*> &vect_obj,
SmartPointer<CSpriteObjectAI> &objectai);
void process();
......@@ -32,7 +34,7 @@ private:
int m_alternate_sprite;
CMessageBox *mp_MessageBox;
CSpriteObject *mp_ShootObject;
CSpriteObjectAI &m_objectai;
SmartPointer<CSpriteObjectAI> mObjectAI;
Uint32 m_timer;
CBitmap *mp_Bitmap;
......
......@@ -83,7 +83,7 @@ void CPlayGameVorticon::processLevelTrigger(int trigger)
mMap->m_Dark = false;
g_pMusicPlayer->stop();
g_pGfxEngine->Palette.setdark(mMap->m_Dark);
mpFinale = new CTantalusRay(mMessageBoxes, mMap, m_Object, *(mpObjectAI.get()) );
mpFinale = new CTantalusRay(mMessageBoxes, mMap, m_Object, mpObjectAI );
m_Player[0].dontdraw = true;
m_gameover = true;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment