SBSPSS/source/friend/fkrusty.cpp

102 lines
1.7 KiB
C++
Raw Normal View History

2001-05-02 23:51:15 +02:00
/*=========================================================================
fkrusty.cpp
Author: CRB
Created:
Project: Spongebob
Purpose:
Copyright (c) 2000 Climax Development Ltd
===========================================================================*/
#ifndef __FRIEND_FKRUSTY_H__
#include "friend\fkrusty.h"
#endif
#ifndef __UTILS_HEADER__
#include "utils\utils.h"
#endif
2001-05-03 00:49:59 +02:00
#ifndef __LEVEL_LEVEL_H__
#include "level\level.h"
#endif
2001-05-02 23:51:15 +02:00
#ifndef __GAME_CONVO_H__
#include "game\convo.h"
#endif
#ifndef __ANIM_KRUSTY_HEADER__
#include <ACTOR_KRUSTY_Anim.h>
#endif
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void CNpcKrustyFriend::postInit()
{
2001-05-03 00:49:59 +02:00
switch( CLevel::getCurrentChapter() )
{
2001-07-19 16:04:59 +02:00
case 3:
2001-05-03 00:49:59 +02:00
{
m_conversation = SCRIPTS_CH4L3_01_DAT;
break;
}
case 2:
{
m_conversation = SCRIPTS_CH2L1_01_DAT;
break;
}
default:
{
m_conversation = SCRIPTS_CH1L4_01_DAT;
break;
}
}
2001-05-02 23:51:15 +02:00
}
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void CNpcKrustyFriend::startConderversation()
{
2001-05-03 15:11:45 +02:00
if( !CConversation::isActive() )
2001-05-02 23:51:15 +02:00
{
2001-05-03 15:11:45 +02:00
CConversation::trigger( m_conversation );
2001-05-02 23:51:15 +02:00
2001-05-03 15:11:45 +02:00
switch( CLevel::getCurrentChapter() )
{
2001-07-19 16:04:59 +02:00
case 3:
2001-05-02 23:51:15 +02:00
{
2001-05-03 15:11:45 +02:00
if ( m_conversation == SCRIPTS_CH4L3_01_DAT )
2001-05-03 00:49:59 +02:00
{
2001-05-03 15:11:45 +02:00
m_conversation = SCRIPTS_CH4L3_02_DAT;
2001-05-03 00:49:59 +02:00
}
2001-05-03 15:11:45 +02:00
break;
}
2001-05-03 00:49:59 +02:00
2001-05-03 15:11:45 +02:00
case 2:
{
if ( m_conversation == SCRIPTS_CH2L1_01_DAT )
{
m_conversation = SCRIPTS_CH2L1_02_DAT;
2001-05-03 00:49:59 +02:00
}
2001-05-03 15:11:45 +02:00
break;
}
2001-05-03 00:49:59 +02:00
2001-05-03 15:11:45 +02:00
default:
{
if ( m_conversation == SCRIPTS_CH1L4_01_DAT )
{
m_conversation = SCRIPTS_CH1L4_02_DAT;
2001-05-03 00:49:59 +02:00
}
2001-05-03 15:11:45 +02:00
break;
2001-05-02 23:51:15 +02:00
}
}
}
}