2016-02-26 02:42:10 +00:00
|
|
|
/* ScummVM - Graphic Adventure Engine
|
|
|
|
*
|
|
|
|
* ScummVM is the legal property of its developers, whose names
|
|
|
|
* are too numerous to list here. Please refer to the COPYRIGHT
|
|
|
|
* file distributed with this source distribution.
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef TITANIC_PARROT_H
|
|
|
|
#define TITANIC_PARROT_H
|
|
|
|
|
|
|
|
#include "titanic/npcs/true_talk_npc.h"
|
2016-12-21 01:50:39 +00:00
|
|
|
#include "titanic/moves/move_player_to.h"
|
2016-02-26 02:42:10 +00:00
|
|
|
|
|
|
|
namespace Titanic {
|
|
|
|
|
2016-12-27 04:22:10 +00:00
|
|
|
enum ParrotState {
|
|
|
|
PARROT_IN_CAGE = 0, PARROT_1 = 1, PARROT_ESCAPED = 2,
|
|
|
|
PARROT_MAILED = 3, PARROT_4 = 4
|
|
|
|
};
|
|
|
|
|
2016-02-26 02:42:10 +00:00
|
|
|
class CParrot : public CTrueTalkNPC {
|
2016-08-14 03:43:52 +00:00
|
|
|
DECLARE_MESSAGE_MAP;
|
|
|
|
bool ActMsg(CActMsg *msg);
|
|
|
|
bool MouseButtonDownMsg(CMouseButtonDownMsg *msg);
|
|
|
|
bool MovieEndMsg(CMovieEndMsg *msg);
|
|
|
|
bool EnterViewMsg(CEnterViewMsg *msg);
|
|
|
|
bool TrueTalkTriggerActionMsg(CTrueTalkTriggerActionMsg *msg);
|
|
|
|
bool MouseDragStartMsg(CMouseDragStartMsg *msg);
|
|
|
|
bool LeaveViewMsg(CLeaveViewMsg *msg);
|
|
|
|
bool ParrotSpeakMsg(CParrotSpeakMsg *msg);
|
|
|
|
bool NPCPlayTalkingAnimationMsg(CNPCPlayTalkingAnimationMsg *msg);
|
|
|
|
bool NPCPlayIdleAnimationMsg(CNPCPlayIdleAnimationMsg *msg);
|
|
|
|
bool FrameMsg(CFrameMsg *msg);
|
|
|
|
bool MovieFrameMsg(CMovieFrameMsg *msg);
|
|
|
|
bool PutParrotBackMsg(CPutParrotBackMsg *msg);
|
|
|
|
bool PreEnterViewMsg(CPreEnterViewMsg *msg);
|
|
|
|
bool PanningAwayFromParrotMsg(CPanningAwayFromParrotMsg *msg);
|
|
|
|
bool LeaveRoomMsg(CLeaveRoomMsg *msg);
|
2017-09-09 19:58:59 +00:00
|
|
|
bool TrueTalkNotifySpeechStartedMsg(CTrueTalkNotifySpeechStartedMsg *msg);
|
2017-02-20 21:44:45 +00:00
|
|
|
bool TrueTalkNotifySpeechEndedMsg(CTrueTalkNotifySpeechEndedMsg *msg);
|
2016-04-15 12:01:39 +00:00
|
|
|
public:
|
2017-01-19 01:54:05 +00:00
|
|
|
static bool _eatingChicken;
|
|
|
|
static bool _takeOff;
|
|
|
|
static bool _unused;
|
2016-12-27 04:22:10 +00:00
|
|
|
static ParrotState _state;
|
2017-01-19 01:54:05 +00:00
|
|
|
static bool _coreReplaced;
|
2016-02-26 02:42:10 +00:00
|
|
|
private:
|
2017-01-21 22:13:18 +00:00
|
|
|
int _unused1;
|
|
|
|
CString _carryParrot;
|
|
|
|
bool _canDrag;
|
|
|
|
int _unused2;
|
2016-12-25 21:42:44 +00:00
|
|
|
uint _lastSpeakTime;
|
2016-12-21 01:50:39 +00:00
|
|
|
int _newXp;
|
|
|
|
int _newXc;
|
2017-07-05 22:23:23 +00:00
|
|
|
bool _triedEatChicken;
|
2017-01-21 22:13:18 +00:00
|
|
|
int _eatOffsetX;
|
2016-12-21 01:50:39 +00:00
|
|
|
CMovePlayerTo *_panTarget;
|
2017-08-20 20:05:41 +00:00
|
|
|
private:
|
|
|
|
/**
|
|
|
|
* Called for the Parrot to start or finish eating
|
|
|
|
*/
|
|
|
|
void setEatingChicken(bool eating);
|
2016-02-26 02:42:10 +00:00
|
|
|
public:
|
2016-07-25 00:30:56 +00:00
|
|
|
CLASSDEF;
|
2016-02-26 02:42:10 +00:00
|
|
|
CParrot();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Save the data for the class to file
|
|
|
|
*/
|
2016-06-29 23:53:16 +00:00
|
|
|
virtual void save(SimpleFile *file, int indent);
|
2016-02-26 02:42:10 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Load the data for the class from file
|
|
|
|
*/
|
|
|
|
virtual void load(SimpleFile *file);
|
|
|
|
};
|
|
|
|
|
|
|
|
} // End of namespace Titanic
|
|
|
|
|
|
|
|
#endif /* TITANIC_PARROT_H */
|