This commit is contained in:
parent
dcdbc83daf
commit
fea6ee4bad
1 changed files with 26 additions and 7 deletions
|
@ -51,6 +51,10 @@
|
||||||
#include "game\game.h"
|
#include "game\game.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef __GAME_GAMESLOT_H__
|
||||||
|
#include "game\gameslot.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/* Std Lib
|
/* Std Lib
|
||||||
------- */
|
------- */
|
||||||
|
@ -355,21 +359,36 @@ void CPauseMenu::render()
|
||||||
---------------------------------------------------------------------- */
|
---------------------------------------------------------------------- */
|
||||||
void CPauseMenu::renderLives()
|
void CPauseMenu::renderLives()
|
||||||
{
|
{
|
||||||
int x,y;
|
CGameSlotManager::GameSlot *gameSlot;
|
||||||
|
int x,y,textYOff;
|
||||||
SpriteBank *sb;
|
SpriteBank *sb;
|
||||||
sFrameHdr *fh;
|
sFrameHdr *fh;
|
||||||
char buf[5];
|
char buf[10];
|
||||||
|
|
||||||
x=345;
|
gameSlot=CGameSlotManager::getSlotData();
|
||||||
y=140;
|
|
||||||
|
// Spat count
|
||||||
|
x=100;
|
||||||
|
y=137;
|
||||||
|
sb=GameScene.getSpriteBank();
|
||||||
|
fh=sb->getFrameHeader(FRM__SPATULA);
|
||||||
|
sb->printFT4(fh,x,y,0,0,0);
|
||||||
|
x+=fh->W;
|
||||||
|
sprintf(buf,"%d/%d",GameScene.getPlayer()->getSpatulasHeld(),GameScene.GetLevel().getTotalSpatCount());
|
||||||
|
textYOff=fh->H-m_fontBank->getStringHeight(buf);
|
||||||
|
y+=textYOff;
|
||||||
|
m_fontBank->print(x,y,buf);
|
||||||
|
|
||||||
|
// Lives
|
||||||
|
x=350;
|
||||||
|
y=137;
|
||||||
sb=GameScene.getSpriteBank();
|
sb=GameScene.getSpriteBank();
|
||||||
fh=sb->getFrameHeader(FRM__PANTS);
|
fh=sb->getFrameHeader(FRM__PANTS);
|
||||||
sb->printFT4(fh,x,y,0,0,0);
|
sb->printFT4(fh,x,y,0,0,0);
|
||||||
x+=fh->W;
|
x+=fh->W;
|
||||||
sprintf(buf,"x5");
|
sprintf(buf,"x%d",gameSlot->m_lives);
|
||||||
y+=fh->H-m_fontBank->getStringHeight(buf);
|
y+=textYOff;
|
||||||
m_fontBank->print(x,y,buf);
|
m_fontBank->print(x,y,buf);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue