23 #ifndef TINSEL_ACTOR_H // prevent multiple includes 24 #define TINSEL_ACTOR_H 27 #include "tinsel/dw.h" 28 #include "tinsel/events.h" 29 #include "tinsel/palette.h" 30 #include "tinsel/movers.h" 45 #define ACTORTAG_KEY 0x1000000 46 #define OTH_RELATEDACTOR 0x00000fff 47 #define OTH_RELATIVE 0x00001000 48 #define OTH_ABSOLUTE 0x00002000 49 #define MAX_TAGACTORS 10 50 #define NUM_ZPOSITIONS 200 // Reasonable-sounding number 72 short presPlayX, presPlayY;
99 void ToggleActor(
int ano,
bool show);
102 void RunCodeToCompletion(
int ano);
103 int GetCount() {
return _numActors; }
105 void RegisterActors(
int num);
106 void SetLeadId(
int rid);
107 bool ActorIsGhost(
int actor);
108 void StartTaggedActors(
SCNHANDLE ah,
int numActors,
bool bRunScript);
111 void DisableActor(
int actor);
112 void EnableActor(
int actor);
114 void Tag_Actor(
int ano,
SCNHANDLE tagtext,
int tp);
115 void UnTagActor(
int ano);
116 void ReTagActor(
int ano);
117 int TagType(
int ano);
119 bool actorAlive(
int ano);
120 int32 actorMaskType(
int ano);
121 void GetActorPos(
int ano,
int *x,
int *y);
122 void GetActorMidTop(
int ano,
int *x,
int *y);
123 int GetActorLeft(
int ano);
124 int GetActorRight(
int ano);
125 int GetActorTop(
int ano);
126 int GetActorBottom(
int ano);
127 bool ActorHidden(
int ano);
128 bool HideMovingActor(
int id,
int sf);
129 void unHideMovingActor(
int id);
130 void restoreMovement(
int id);
131 void storeActorReel(
int ano,
const FREEL *reel,
SCNHANDLE hFilm,
OBJECT *pobj,
int reelnum,
int x,
int y);
132 const FREEL *actorReel(
int ano);
134 void SetActorPlayFilm(
int ano,
SCNHANDLE hFilm);
136 void SetActorTalkFilm(
int ano,
SCNHANDLE hFilm);
139 void SetActorTalking(
int ano,
bool tf);
140 bool ActorIsTalking(
int ano);
141 void SetActorLatestFilm(
int ano,
SCNHANDLE hFilm);
144 void UpdateActorEsc(
int ano,
bool escOn,
int escEvent);
145 void UpdateActorEsc(
int ano,
int escEvent);
146 bool ActorEsc(
int ano);
147 int ActorEev(
int ano);
148 void StoreActorPos(
int ano,
int x,
int y);
149 void StoreActorSteps(
int ano,
int steps);
150 int GetActorSteps(
int ano);
152 void StoreActorZpos(
int ano,
int z,
int column = -1);
153 int GetActorZpos(
int ano,
int column);
154 void IncLoopCount(
int ano);
155 int GetLoopCount(
int ano);
157 void FirstTaggedActor();
158 int NextTaggedActor();
159 int NextTaggedActor(
int previous);
160 int AsetZPos(
OBJECT *pObj,
int y, int32 zFactor);
162 void storeActorAttr(
int ano,
int r1,
int g1,
int b1);
163 COLORREF GetActorRGB(
int ano);
164 void SetActorRGB(
int ano, COLORREF color);
165 void SetActorZfactor(
int ano, uint32 zFactor);
166 uint32 GetActorZfactor(
int ano);
168 void ActorsLife(
int id,
bool bAlive);
169 void dwEndActor(
int ano);
171 void SetActorPointedTo(
int actor,
bool bPointedTo);
172 bool ActorIsPointedTo(
int actor);
173 void SetActorTagWanted(
int actor,
bool bTagWanted,
bool bCursor,
SCNHANDLE hOverrideTag);
174 bool ActorTagIsWanted(
int actor);
175 bool InHotSpot(
int ano,
int curX,
int curY);
176 int FrontTaggedActor();
177 void GetActorTagPos(
int actor,
int *pTagX,
int *pTagY,
bool bAbsolute);
178 bool IsTaggedActor(
int actor);
180 void StoreActorPresFilm(
int ano,
SCNHANDLE hFilm,
int x,
int y);
182 int GetActorFilmNumber(
int ano);
184 void StoreActorReel(
int actor,
int column,
OBJECT *pObj);
185 void NotPlayingReel(
int actor,
int filmNumber,
int column);
186 bool ActorReelPlaying(
int actor,
int column);
189 void RestoreActors(
int numActors,
SAVED_ACTOR *sActorInfo);
191 void SaveZpositions(
void *zpp);
192 void RestoreZpositions(
void *zpp);
194 void SaveActorZ(byte *saveActorZ);
195 void RestoreActorZ(byte *saveActorZ);
197 int TaggedActorIndex(
int actor);
202 void StartActor(
const ACTORDATA *ad,
bool bRunScript);
203 void GetActorTagPortion(
int ano,
unsigned *top,
unsigned *bottom,
unsigned *left,
unsigned *right);
205 ACTORINFO *_actorInfo;
206 COLORREF _defaultColor;
210 int _numTaggedActors;
219 void ActorEvent(
int ano,
TINSEL_EVENT event, PLR_EVENT be);
221 void ActorEvent(
int ano,
TINSEL_EVENT tEvent,
bool bWait,
int myEscape,
bool *result = NULL);
224 void RestoreActorProcess(
int id,
INT_CONTEXT *pic,
bool savegameFlag);
SCNHANDLE hActorId
handle actor ID string index
Definition: actors.h:83
uint32 SCNHANDLE
Definition: dw.h:31
int32 masking
type of actor masking (Tinsel V1)
Definition: actors.h:82
SCNHANDLE hActorCode
handle to actor script
Definition: actors.h:84
Definition: serializer.h:79
TINSEL_EVENT
Definition: events.h:91
SCNHANDLE presFilm
the film that reel belongs to
Definition: actors.h:70
#define CORO_PARAM
Definition: coroutines.h:107
Definition: algorithm.h:29
short presRnum
the present reel number
Definition: actors.h:71