This commit is contained in:
parent
d739a44367
commit
22225dfb99
2 changed files with 20 additions and 2 deletions
|
@ -1,3 +1,4 @@
|
||||||
|
int counter=0;
|
||||||
/**********************/
|
/**********************/
|
||||||
/*** Main Game File ***/
|
/*** Main Game File ***/
|
||||||
/**********************/
|
/**********************/
|
||||||
|
@ -177,6 +178,7 @@ int CGameScene::s_restartLevel;
|
||||||
int CGameScene::s_bossHasBeenKilled;
|
int CGameScene::s_bossHasBeenKilled;
|
||||||
int CGameScene::s_justHitBossArenaTrigger;
|
int CGameScene::s_justHitBossArenaTrigger;
|
||||||
DVECTOR CGameScene::s_CamShake={0,0};
|
DVECTOR CGameScene::s_CamShake={0,0};
|
||||||
|
int CGameScene::s_showBossTextOnRespawn;
|
||||||
|
|
||||||
|
|
||||||
// Evil global pointer to the boss character
|
// Evil global pointer to the boss character
|
||||||
|
@ -223,6 +225,7 @@ void CGameScene::init()
|
||||||
m_gamestate=GAMESTATE_SHOWING_LIVES;
|
m_gamestate=GAMESTATE_SHOWING_LIVES;
|
||||||
m_showingLivesTimer=0;
|
m_showingLivesTimer=0;
|
||||||
|
|
||||||
|
s_showBossTextOnRespawn=false;
|
||||||
}
|
}
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
// This is a seperate funtion ( and virtual ) so that we can overload it for
|
// This is a seperate funtion ( and virtual ) so that we can overload it for
|
||||||
|
@ -451,6 +454,8 @@ void CGameScene::think(int _frames)
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
counter+=_frames;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -726,7 +731,15 @@ void CGameScene::respawnLevel()
|
||||||
CSoundMediator::setCanPlaySfx(false);
|
CSoundMediator::setCanPlaySfx(false);
|
||||||
m_player->respawn();
|
m_player->respawn();
|
||||||
Level.respawnLevel();
|
Level.respawnLevel();
|
||||||
|
if(!s_showBossTextOnRespawn)
|
||||||
|
{
|
||||||
m_gamestate=GAMESTATE_SHOWING_LIVES;
|
m_gamestate=GAMESTATE_SHOWING_LIVES;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
m_gamestate=GAMESTATE_SHOWING_LIVES_BUT_GOING_TO_BOSS_TEXT;
|
||||||
|
m_bossText->select();
|
||||||
|
}
|
||||||
m_showingLivesTimer=0;
|
m_showingLivesTimer=0;
|
||||||
CSoundMediator::setCanPlaySfx(true);
|
CSoundMediator::setCanPlaySfx(true);
|
||||||
}
|
}
|
||||||
|
@ -750,8 +763,12 @@ void CGameScene::setReadyToExit()
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
void CGameScene::hitBossArenaTrigger()
|
void CGameScene::hitBossArenaTrigger()
|
||||||
|
{
|
||||||
|
if(!s_showBossTextOnRespawn)
|
||||||
{
|
{
|
||||||
s_justHitBossArenaTrigger=true;
|
s_justHitBossArenaTrigger=true;
|
||||||
|
s_showBossTextOnRespawn=true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
|
@ -138,6 +138,7 @@ static SpriteBank *s_GlobalSpritebank;
|
||||||
static CLayerCollision *s_GlobalCollision;
|
static CLayerCollision *s_GlobalCollision;
|
||||||
static int s_bossHasBeenKilled;
|
static int s_bossHasBeenKilled;
|
||||||
static DVECTOR s_CamShake;
|
static DVECTOR s_CamShake;
|
||||||
|
static int s_showBossTextOnRespawn;
|
||||||
|
|
||||||
|
|
||||||
int m_levelHasTimer;
|
int m_levelHasTimer;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue