1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
|
/* 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.
*
* $URL$
* $Id$
*
* Prototypes of actor functions
*/
#ifndef TINSEL_ACTOR_H // prevent multiple includes
#define TINSEL_ACTOR_H
#include "tinsel/dw.h" // for SCNHANDLE
#include "tinsel/events.h" // for USER_EVENT
#include "tinsel/palette.h" // for COLORREF
namespace Tinsel {
struct FREEL;
struct INT_CONTEXT;
struct MACTOR;
struct OBJECT;
/*----------------------------------------------------------------------*/
void RegisterActors(int num);
void FreeActors(void);
void setleadid(int rid);
int LeadId(void);
void StartActors(SCNHANDLE ah, int numActors, bool bRunScript);
void DropActors(void); // No actor reels running
void DisableActor(int actor);
void EnableActor(int actor);
void Tag_Actor(int ano, SCNHANDLE tagtext, int tp);
void UnTagActor(int ano);
void ReTagActor(int ano);
int TagType(int ano);
bool actorAlive(int ano);
int32 actorMaskType(int ano);
void GetActorPos(int ano, int *x, int *y);
void SetActorPos(int ano, int x, int y);
void GetActorMidTop(int ano, int *x, int *y);
int GetActorLeft(int ano);
int GetActorRight(int ano);
int GetActorTop(int ano);
int GetActorBottom(int ano);
void HideActor(int ano);
bool HideMovingActor(int id, int sf);
void unHideMovingActor(int id);
void restoreMovement(int id);
void storeActorReel(int ano, const FREEL *reel, SCNHANDLE film, OBJECT *pobj, int reelnum, int x, int y);
const FREEL *actorReel(int ano);
SCNHANDLE actorFilm(int ano);
void setActorPlayFilm(int ano, SCNHANDLE film);
SCNHANDLE getActorPlayFilm(int ano);
void setActorTalkFilm(int ano, SCNHANDLE film);
SCNHANDLE getActorTalkFilm(int ano);
void setActorTalking(int ano, bool tf);
bool isActorTalking(int ano);
void setActorLatestFilm(int ano, SCNHANDLE film);
SCNHANDLE getActorLatestFilm(int ano);
void updateActorEsc(int ano, bool escOn, int escEv);
bool actorEsc(int ano);
int actorEev(int ano);
void storeActorPos(int ano, int x, int y);
void storeActorSteps(int ano, int steps);
int getActorSteps(int ano);
void storeActorZpos(int ano, int z);
SCNHANDLE GetActorTag(int ano);
void FirstTaggedActor(void);
int NextTaggedActor(void);
int AsetZPos(OBJECT *pObj, int y, int32 zFactor);
void MAsetZPos(MACTOR *pActor, int y, int32 zFactor);
void actorEvent(int ano, USER_EVENT event, BUTEVENT be);
void storeActorAttr(int ano, int r1, int g1, int b1);
COLORREF getActorTcol(int ano);
void setactorson(void);
void ActorsLife(int id, bool bAlive);
/*----------------------------------------------------------------------*/
struct SAVED_ACTOR {
short actorID;
short z;
bool bAlive;
SCNHANDLE presFilm; //!< the film that reel belongs to
short presRnum; //!< the present reel number
short presX, presY;
};
int SaveActors(SAVED_ACTOR *sActorInfo);
void RestoreActorProcess(int id, INT_CONTEXT *pic);
/*----------------------------------------------------------------------*/
} // end of namespace Tinsel
#endif /* TINSEL_ACTOR_H */
|