2001-07-11 18:56:56 +02:00
|
|
|
/*=========================================================================
|
|
|
|
|
|
|
|
nicklogo.cpp
|
|
|
|
|
|
|
|
Author: PKG
|
|
|
|
Created:
|
|
|
|
Project: Spongebob
|
|
|
|
Purpose:
|
|
|
|
|
|
|
|
Copyright (c) 2000 Climax Development Ltd
|
|
|
|
|
|
|
|
===========================================================================*/
|
|
|
|
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Includes
|
|
|
|
-------- */
|
|
|
|
|
|
|
|
#include "frontend\nicklogo.h"
|
|
|
|
|
|
|
|
#ifndef __GFX_FADER_H__
|
|
|
|
#include "gfx\fader.h"
|
|
|
|
#endif
|
|
|
|
|
2001-07-11 20:32:45 +02:00
|
|
|
#ifndef _FILEIO_HEADER_
|
|
|
|
#include "fileio\fileio.h"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __VID_HEADER_
|
|
|
|
#include "system\vid.h"
|
2001-07-11 18:56:56 +02:00
|
|
|
#endif
|
|
|
|
|
2001-07-18 16:59:15 +02:00
|
|
|
#ifndef __PAD_PADS_H__
|
|
|
|
#include "pad\pads.h"
|
|
|
|
#endif
|
|
|
|
|
2001-07-11 18:56:56 +02:00
|
|
|
|
|
|
|
/* Std Lib
|
|
|
|
------- */
|
|
|
|
|
|
|
|
/* Data
|
|
|
|
---- */
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Tyepdefs && Defines
|
|
|
|
------------------- */
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Structure defintions
|
|
|
|
-------------------- */
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Function Prototypes
|
|
|
|
------------------- */
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Vars
|
|
|
|
---- */
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Function:
|
|
|
|
Purpose:
|
|
|
|
Params:
|
|
|
|
Returns:
|
|
|
|
---------------------------------------------------------------------- */
|
|
|
|
void CFrontEndNickLogo::select()
|
|
|
|
{
|
2001-07-11 20:32:45 +02:00
|
|
|
m_readyToExit=false;
|
|
|
|
|
2001-07-28 18:45:46 +02:00
|
|
|
m_image=LoadPakScreen(BACKDROP_NICK_GFX);
|
2001-07-11 20:32:45 +02:00
|
|
|
ASSERT(m_image);
|
|
|
|
SetScreenImage(m_image);
|
|
|
|
|
|
|
|
CFader::setFadingIn();
|
|
|
|
m_frameCount=0;
|
|
|
|
}
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Function:
|
|
|
|
Purpose:
|
|
|
|
Params:
|
|
|
|
Returns:
|
|
|
|
---------------------------------------------------------------------- */
|
|
|
|
void CFrontEndNickLogo::unselect()
|
|
|
|
{
|
|
|
|
MemFree(m_image); m_image=NULL;
|
|
|
|
}
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Function:
|
|
|
|
Purpose:
|
|
|
|
Params:
|
|
|
|
Returns:
|
|
|
|
---------------------------------------------------------------------- */
|
|
|
|
void CFrontEndNickLogo::think(int _frames)
|
|
|
|
{
|
2001-07-13 18:10:02 +02:00
|
|
|
if(!CFader::isFading())
|
2001-07-11 20:32:45 +02:00
|
|
|
{
|
2001-07-13 18:10:02 +02:00
|
|
|
m_frameCount+=_frames;
|
|
|
|
|
2001-07-18 16:59:15 +02:00
|
|
|
if(!m_readyToExit&&
|
|
|
|
(PadGetDown(0)&(PAD_CROSS|PAD_START)||m_frameCount>DISPLAY_FRAMES))
|
2001-07-13 18:10:02 +02:00
|
|
|
{
|
|
|
|
CFader::setFadingOut();
|
|
|
|
m_readyToExit=true;
|
|
|
|
}
|
2001-07-11 20:32:45 +02:00
|
|
|
}
|
2001-07-11 18:56:56 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Function:
|
|
|
|
Purpose:
|
|
|
|
Params:
|
|
|
|
Returns:
|
|
|
|
---------------------------------------------------------------------- */
|
|
|
|
int CFrontEndNickLogo::isReadyToExit()
|
|
|
|
{
|
2001-07-11 20:32:45 +02:00
|
|
|
return !CFader::isFading()&&m_readyToExit;
|
2001-07-11 18:56:56 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
/*----------------------------------------------------------------------
|
|
|
|
Function:
|
|
|
|
Purpose:
|
|
|
|
Params:
|
|
|
|
Returns:
|
|
|
|
---------------------------------------------------------------------- */
|
|
|
|
CFrontEndScene::FrontEndMode CFrontEndNickLogo::getNextMode()
|
|
|
|
{
|
|
|
|
return CFrontEndScene::MODE__FMV_THQ;
|
|
|
|
}
|
|
|
|
|
|
|
|
/*===========================================================================
|
|
|
|
end */
|