ScummVM API documentation
types.h
1/* ScummVM - Graphic Adventure Engine
2 *
3 * ScummVM is the legal property of its developers, whose names
4 * are too numerous to list here. Please refer to the COPYRIGHT
5 * file distributed with this source distribution.
6 *
7 * Additional copyright for this file:
8 * Copyright (C) 1995-1997 Presto Studios, Inc.
9 *
10 * This program is free software: you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation, either version 3 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 *
20 * You should have received a copy of the GNU General Public License
21 * along with this program. If not, see <http://www.gnu.org/licenses/>.
22 *
23 */
24
25#ifndef PEGASUS_TYPES_H
26#define PEGASUS_TYPES_H
27
28#include "common/scummsys.h"
29
30namespace Pegasus {
31
32// TODO: Probably all of these don't really need to be typedef'd...
33
34typedef int32 DisplayElementID;
35typedef int32 DisplayOrder;
36
37typedef int16 HotSpotID;
38typedef uint32 HotSpotFlags;
39
40typedef byte ButtonState;
41typedef uint32 InputBits;
42
43typedef int32 NotificationID;
44typedef uint32 NotificationFlags;
45
46// Mac types.
47typedef int16 ResIDType;
48typedef int16 CoordType;
49
50enum SlideDirection {
51 kSlideLeftMask = 1,
52 kSlideRightMask = kSlideLeftMask << 1,
53 kSlideUpMask = kSlideRightMask << 1 << 1,
54 kSlideDownMask = kSlideUpMask << 1,
55
56 kSlideHorizMask = kSlideLeftMask | kSlideRightMask,
57 kSlideVertMask = kSlideUpMask | kSlideDownMask,
58
59 kSlideUpLeftMask = kSlideLeftMask | kSlideUpMask,
60 kSlideUpRightMask = kSlideRightMask | kSlideUpMask,
61 kSlideDownLeftMask = kSlideLeftMask | kSlideDownMask,
62 kSlideDownRightMask = kSlideRightMask | kSlideDownMask
63};
64
65// ScummVM QuickTime/QuickDraw replacement types
66typedef uint TimeValue;
67typedef uint TimeScale;
68
69typedef int16 GameID;
70
71typedef GameID ItemID;
72typedef GameID ActorID;
73typedef GameID RoomID;
74typedef GameID NeighborhoodID;
75typedef byte AlternateID;
76typedef int8 HotSpotActivationID;
77
78typedef int16 WeightType;
79
80typedef byte DirectionConstant;
81typedef byte TurnDirection;
82
83// Meant to be room in low 16 bits and direction in high 16 bits.
84typedef uint32 RoomViewID;
85
86#define MakeRoomView(room, direction) (((RoomViewID) (room)) | (((RoomViewID) (direction)) << 16))
87
88typedef uint32 ExtraID;
89
90typedef int16 GameMode;
91
92typedef int16 WeightType;
93
94typedef int16 ItemState;
95
96typedef int8 DeathReason;
97
98typedef int32 GameMenuCommand;
99
100typedef int32 GameScoreType;
101
102typedef long CanMoveForwardReason;
103
104typedef long CanTurnReason;
105
106typedef long CanOpenDoorReason;
107
108enum InventoryResult {
109 kInventoryOK,
110 kTooMuchWeight,
111 kItemNotInInventory
112};
113
114typedef int32 InteractionID;
115
116typedef int32 AIConditionID;
117
118enum EnergyStage {
119 kStageNoStage,
120 kStageCasual, // more than 50% energy
121 kStageWorried, // more than 25% energy
122 kStageNervous, // more than 5% energy
123 kStagePanicStricken // less than 5% energy
124};
125
126enum NoradSubPrepState {
127 kSubNotPrepped,
128 kSubPrepped,
129 kSubDamaged
130};
131
132enum LowerClientSignature {
133 kNoClientSignature,
134 kInventorySignature,
135 kBiochipSignature,
136 kAISignature
137};
138
139enum LowerAreaSignature {
140 kLeftAreaSignature,
141 kMiddleAreaSignature,
142 kRightAreaSignature
143};
144
145enum AirQuality {
146 kAirQualityGood,
147 kAirQualityDirty,
148 kAirQualityVacuum
149};
150
151enum DragType {
152 kDragNoDrag,
153 kDragInventoryPickup,
154 kDragBiochipPickup,
155 kDragInventoryUse
156};
157
158} // End of namespace Pegasus
159
160#endif