1 // ============================================================================
2 // Mirror Magic -- McDuffin's Revenge
3 // ----------------------------------------------------------------------------
4 // (c) 1994-2017 by Artsoft Entertainment
7 // https://www.artsoft.org/
8 // ----------------------------------------------------------------------------
10 // ============================================================================
18 // for DrawElementShifted
20 #define CUT_ABOVE (1 << 0)
21 #define CUT_BELOW (1 << 1)
22 #define CUT_LEFT (1 << 2)
23 #define CUT_RIGHT (1 << 3)
25 // for masking functions
30 #define DOOR_OPEN_1 (1 << 0)
31 #define DOOR_OPEN_2 (1 << 1)
32 #define DOOR_CLOSE_1 (1 << 2)
33 #define DOOR_CLOSE_2 (1 << 3)
34 #define DOOR_OPEN_ALL (DOOR_OPEN_1 | DOOR_OPEN_2)
35 #define DOOR_CLOSE_ALL (DOOR_CLOSE_1 | DOOR_CLOSE_2)
36 #define DOOR_ACTION_1 (DOOR_OPEN_1 | DOOR_CLOSE_1)
37 #define DOOR_ACTION_2 (DOOR_OPEN_2 | DOOR_CLOSE_2)
38 #define DOOR_ACTION (DOOR_ACTION_1 | DOOR_ACTION_2)
39 #define DOOR_COPY_BACK (1 << 4)
40 #define DOOR_NO_DELAY (1 << 5)
41 #define DOOR_GET_STATE (1 << 6)
44 #define REQ_ASK (1 << 0)
45 #define REQ_OPEN (1 << 1)
46 #define REQ_CLOSE (1 << 2)
47 #define REQ_CONFIRM (1 << 3)
48 #define REQ_STAY_CLOSED (1 << 4)
49 #define REQ_STAY_OPEN (1 << 5)
52 void SetDrawtoField_MM(int);
53 void BackToFront(void);
54 void FadeToFront(void);
55 void ClearWindow(void);
57 void MarkTileDirty(int, int);
59 void DrawAllPlayers_MM(void);
60 void DrawPlayerField_MM(int, int);
61 void DrawPlayer_MM(struct PlayerInfo *);
62 void DrawGraphicAnimation_MM(int, int, int, int);
64 void DrawGraphic_MM(int, int, int);
65 void DrawGraphicExt_MM(DrawBuffer *, int, int, int);
66 void DrawGraphicThruMask_MM(int, int, int, int);
67 void DrawGraphicThruMaskExt_MM(DrawBuffer *, int, int, int, int);
68 void DrawMiniGraphic_MM(int, int, int);
69 void getMiniGraphicSource(int, Bitmap **, int *, int *);
70 void DrawMiniGraphicExt_MM(DrawBuffer *, int, int, int);
71 void DrawGraphicShifted_MM(int, int, int, int, int, int, int);
72 void DrawScreenElementExt_MM(int, int, int, int, int, int, int);
73 void DrawLevelElementExt_MM(int, int, int, int, int, int, int);
74 void DrawScreenElementShifted_MM(int, int, int, int, int, int);
75 void ErdreichAnbroeckeln(int, int);
76 void DrawScreenElement_MM(int, int, int);
77 void DrawScreenField_MM(int, int);
78 void DrawLevelField_MM(int, int);
79 void DrawMiniElement_MM(int, int, int);
80 void DrawMiniElementOrWall_MM(int, int, int, int);
82 void DrawField_MM(int, int);
83 void DrawLevel_MM(void);
84 void DrawLaser_MM(void);
85 void DrawElement_MM(int, int, int);
86 void DrawWallsExt_MM(int, int, int, int);
87 void DrawWalls_MM(int, int, int);
88 void DrawWallsAnimation_MM(int, int, int, int, int);
89 void DrawMicroLevel_MM(int, int, boolean);
90 void DrawTileCursor_MM(int, boolean);
92 boolean Request(char *, unsigned int);
93 unsigned int OpenDoor(unsigned int);
94 unsigned int CloseDoor(unsigned int);
95 unsigned int GetDoorState(void);
96 unsigned int MoveDoor(unsigned int);
97 void DrawSpecialEditorDoor_MM(void);
98 void UndrawSpecialEditorDoor(void);
99 Pixel ReadPixel(DrawBuffer *, int, int);
101 void CreateToolButtons(void);
103 int get_base_element(int);
104 int get_element_phase(int);
105 int get_num_elements(int);
106 int get_rotated_element(int, int);
108 int map_wall_from_base_element(int);
109 int map_wall_to_base_element(int);
112 int el_act2gfx(int, int);