#define KEY_BUTTON (KEY_BUTTON_1 | KEY_BUTTON_2)
#define KEY_ACTION (KEY_MOTION | KEY_BUTTON)
-#define SET_FOCUS (1 << BIT_SET_FOCUS)
+#define KEY_SET_FOCUS (1 << BIT_SET_FOCUS)
#define MV_DIR_FROM_BIT(x) ((x) < NUM_DIRECTIONS ? 1 << (x) : \
(x) == MV_BIT_UPLEFT ? MV_UPLEFT : \
#define ANIM_RANDOM (1 << 4)
#define ANIM_CE_VALUE (1 << 5)
#define ANIM_CE_SCORE (1 << 6)
-#define ANIM_REVERSE (1 << 7)
-#define ANIM_OPAQUE_PLAYER (1 << 8)
+#define ANIM_CE_DELAY (1 << 7)
+#define ANIM_REVERSE (1 << 8)
+#define ANIM_OPAQUE_PLAYER (1 << 9)
/* values for special (non game element) animation modes */
-#define ANIM_HORIZONTAL (1 << 9)
-#define ANIM_VERTICAL (1 << 10)
-#define ANIM_STATIC_PANEL (1 << 11)
+#define ANIM_HORIZONTAL (1 << 10)
+#define ANIM_VERTICAL (1 << 11)
+#define ANIM_STATIC_PANEL (1 << 12)
#define ANIM_DEFAULT ANIM_LOOP
#define REDRAW_FPS (1 << 11)
#define REDRAWTILES_THRESHOLD (SCR_FIELDX * SCR_FIELDY / 2)
+#define FADE_MODE_FADE_IN 0
+#define FADE_MODE_FADE_OUT 1
+#define FADE_MODE_CROSSFADE 2
+
#define IN_GFX_SCREEN(x, y) (x >= gfx.sx && x < gfx.sx + gfx.sxsize && \
y >= gfx.sy && y < gfx.sy + gfx.sysize)
#define IN_GFX_DOOR(x, y) (x >= gfx.dx && x < gfx.dx + gfx.dxsize && \
#define ARTWORK_FIRST_NODE(artwork, type) \
((type) == ARTWORK_TYPE_GRAPHICS ? \
- (artwork).gfx_first : \
+ (artwork).gfx_first : \
(type) == ARTWORK_TYPE_SOUNDS ? \
- (artwork).snd_first : \
+ (artwork).snd_first : \
(artwork).mus_first)
#define ARTWORK_CURRENT_IDENTIFIER_PTR(artwork, type) \
struct FontBitmapInfo
{
Bitmap *bitmap;
+
int src_x, src_y; /* start position of animation frames */
int width, height; /* width/height of each animation frame */
- int draw_x, draw_y; /* offset for drawing font characters */
+
+ int draw_xoffset; /* offset for drawing font characters */
+ int draw_yoffset; /* offset for drawing font characters */
+
int num_chars;
int num_chars_per_line;
boolean el_dynamic;
boolean el_headlines;
+
+ boolean el_by_game;
+ boolean el_by_type;
+
+ boolean show_element_token;
};
struct SetupEditorCascadeInfo
boolean soft_scrolling;
boolean fading;
boolean autorecord;
+ boolean show_titlescreen;
boolean quick_doors;
boolean team_mode;
boolean handicap;
boolean ask_on_escape;
boolean ask_on_escape_editor;
boolean quick_switch;
+ boolean input_on_focus;
+ boolean prefer_aga_graphics;
char *graphics_set;
char *sounds_set;
char *imported_from; /* optional comment for imported levels or artwork */
char *imported_by; /* optional comment for imported levels or artwork */
+ char *graphics_set_ecs; /* special EMC custom graphics set (ECS graphics) */
+ char *graphics_set_aga; /* special EMC custom graphics set (AGA graphics) */
char *graphics_set; /* optional custom graphics set (level tree only) */
char *sounds_set; /* optional custom sounds set (level tree only) */
char *music_set; /* optional custom music set (level tree only) */
void SetMainBackgroundBitmap(Bitmap *);
void SetDoorBackgroundBitmap(Bitmap *);
-inline void InitVideoDisplay(void);
-inline void CloseVideoDisplay(void);
-inline void InitVideoBuffer(DrawBuffer **,DrawWindow **, int,int,int, boolean);
-inline Bitmap *CreateBitmapStruct(void);
-inline Bitmap *CreateBitmap(int, int, int);
-inline void FreeBitmap(Bitmap *);
-inline void BlitBitmap(Bitmap *, Bitmap *, int, int, int, int, int, int);
-inline void FillRectangle(Bitmap *, int, int, int, int, Pixel);
-inline void ClearRectangle(Bitmap *, int, int, int, int);
-inline void ClearRectangleOnBackground(Bitmap *, int, int, int, int);
-inline void SetClipMask(Bitmap *, GC, Pixmap);
-inline void SetClipOrigin(Bitmap *, GC, int, int);
-inline void BlitBitmapMasked(Bitmap *, Bitmap *, int, int, int, int, int, int);
-inline boolean DrawingOnBackground(int, int);
-inline void BlitBitmapOnBackground(Bitmap *, Bitmap *, int, int, int, int, int,
- int);
-inline void DrawSimpleBlackLine(Bitmap *, int, int, int, int);
-inline void DrawSimpleWhiteLine(Bitmap *, int, int, int, int);
-inline void DrawLines(Bitmap *, struct XY *, int, Pixel);
-inline Pixel GetPixel(Bitmap *, int, int);
-inline Pixel GetPixelFromRGB(Bitmap *, unsigned int,unsigned int,unsigned int);
-inline Pixel GetPixelFromRGBcompact(Bitmap *, unsigned int);
-
-inline void FlushDisplay(void);
-inline void SyncDisplay(void);
-inline void KeyboardAutoRepeatOn(void);
-inline void KeyboardAutoRepeatOff(void);
-inline boolean PointerInWindow(DrawWindow *);
-inline boolean SetVideoMode(boolean);
-inline boolean ChangeVideoModeIfNeeded(boolean);
+void InitVideoDisplay(void);
+void CloseVideoDisplay(void);
+void InitVideoBuffer(DrawBuffer **,DrawWindow **, int,int,int, boolean);
+Bitmap *CreateBitmapStruct(void);
+Bitmap *CreateBitmap(int, int, int);
+void FreeBitmap(Bitmap *);
+void BlitBitmap(Bitmap *, Bitmap *, int, int, int, int, int, int);
+void FadeScreen(Bitmap *bitmap, int, int, int);
+void FillRectangle(Bitmap *, int, int, int, int, Pixel);
+void ClearRectangle(Bitmap *, int, int, int, int);
+void ClearRectangleOnBackground(Bitmap *, int, int, int, int);
+void SetClipMask(Bitmap *, GC, Pixmap);
+void SetClipOrigin(Bitmap *, GC, int, int);
+void BlitBitmapMasked(Bitmap *, Bitmap *, int, int, int, int, int, int);
+boolean DrawingOnBackground(int, int);
+void BlitBitmapOnBackground(Bitmap *, Bitmap *, int, int, int, int, int, int);
+void DrawSimpleBlackLine(Bitmap *, int, int, int, int);
+void DrawSimpleWhiteLine(Bitmap *, int, int, int, int);
+void DrawLines(Bitmap *, struct XY *, int, Pixel);
+Pixel GetPixel(Bitmap *, int, int);
+Pixel GetPixelFromRGB(Bitmap *, unsigned int,unsigned int,unsigned int);
+Pixel GetPixelFromRGBcompact(Bitmap *, unsigned int);
+
+void FlushDisplay(void);
+void SyncDisplay(void);
+void KeyboardAutoRepeatOn(void);
+void KeyboardAutoRepeatOff(void);
+boolean PointerInWindow(DrawWindow *);
+boolean SetVideoMode(boolean);
+boolean ChangeVideoModeIfNeeded(boolean);
Bitmap *LoadImage(char *);
Bitmap *LoadCustomImage(char *);
Bitmap *ZoomBitmap(Bitmap *, int, int);
void CreateBitmapWithSmallBitmaps(Bitmap *, int);
+void ScaleBitmap(Bitmap *, int);
void SetMouseCursor(int);
-inline void OpenAudio(void);
-inline void CloseAudio(void);
-inline void SetAudioMode(boolean);
-
-inline void InitEventFilter(EventFilter);
-inline boolean PendingEvent(void);
-inline void NextEvent(Event *event);
-inline void PeekEvent(Event *event);
-inline Key GetEventKey(KeyEvent *, boolean);
-inline KeyMod HandleKeyModState(Key, int);
-inline KeyMod GetKeyModState();
-inline boolean CheckCloseWindowEvent(ClientMessageEvent *);
-
-inline void InitJoysticks();
-inline boolean ReadJoystick(int, int *, int *, boolean *, boolean *);
+void OpenAudio(void);
+void CloseAudio(void);
+void SetAudioMode(boolean);
+
+void InitEventFilter(EventFilter);
+boolean PendingEvent(void);
+void NextEvent(Event *event);
+void PeekEvent(Event *event);
+Key GetEventKey(KeyEvent *, boolean);
+KeyMod HandleKeyModState(Key, int);
+KeyMod GetKeyModState();
+boolean CheckCloseWindowEvent(ClientMessageEvent *);
+
+void InitJoysticks();
+boolean ReadJoystick(int, int *, int *, boolean *, boolean *);
#endif /* SYSTEM_H */