1 // ============================================================================
2 // Mirror Magic -- McDuffin's Revenge
3 // ----------------------------------------------------------------------------
4 // (c) 1994-2017 by Artsoft Entertainment
7 // https://www.artsoft.org/
8 // ----------------------------------------------------------------------------
10 // ============================================================================
19 struct EngineSnapshotInfo_MM engine_snapshot_mm;
22 void InitGfxBuffers_MM(void)
24 ReCreateBitmap(&drawto_mm, video.width, video.height);
27 unsigned int InitEngineRandom_MM(int seed)
29 return InitEngineRandom(seed);
32 void InitElementProperties_MM(void)
36 static int ep_grid[] =
47 static int ep_grid_num = sizeof(ep_grid) / sizeof(int);
49 static int ep_mcduffin[] =
56 static int ep_mcduffin_num = sizeof(ep_mcduffin) / sizeof(int);
58 static int ep_rectangle[] =
69 static int ep_rectangle_num = sizeof(ep_rectangle) / sizeof(int);
71 static int ep_mirror[] =
90 static int ep_mirror_num = sizeof(ep_mirror) / sizeof(int);
92 static int ep_mirror_fixed[] =
99 static int ep_mirror_fixed_num = sizeof(ep_mirror_fixed) / sizeof(int);
101 static int ep_polar[] =
120 static int ep_polar_num = sizeof(ep_polar) / sizeof(int);
122 static int ep_polar_cross[] =
129 static int ep_polar_cross_num = sizeof(ep_polar_cross) / sizeof(int);
131 static int ep_beamer[] =
150 static int ep_beamer_num = sizeof(ep_beamer) / sizeof(int);
152 static int ep_reflecting[] =
155 static int ep_reflecting_num = sizeof(ep_reflecting) / sizeof(int);
157 static int ep_absorbing[] =
160 static int ep_absorbing_num = sizeof(ep_absorbing) / sizeof(int);
162 static int ep_inactive[] =
165 static int ep_inactive_num = sizeof(ep_inactive) / sizeof(int);
167 static int ep_wall[] =
170 static int ep_wall_num = sizeof(ep_wall) / sizeof(int);
172 static int ep_pacman[] =
179 static int ep_pacman_num = sizeof(ep_pacman) / sizeof(int);
181 static int ep_envelope[] =
188 static int ep_envelope_num = sizeof(ep_envelope) / sizeof(int);
190 static long ep_bit[] =
207 static int *ep_array[] =
224 static int *ep_num[] =
230 &ep_mirror_fixed_num,
241 static int num_properties = sizeof(ep_num) / sizeof(int *);
243 for (i = 0; i < MAX_ELEMENTS; i++)
244 Elementeigenschaften[i] = 0;
246 for (i = 0; i < num_properties; i++)
247 for (j = 0; j < *(ep_num[i]); j++)
248 Elementeigenschaften[(ep_array[i])[j]] |= ep_bit[i];
250 for (i = EL_CHAR_START; i <= EL_CHAR_END; i++)
251 Elementeigenschaften[i] |= (EP_BIT_CHAR | EP_BIT_INACTIVE);
253 for (i = EL_WALL_START; i <= EL_WALL_END; i++)
254 Elementeigenschaften[i] |= EP_BIT_WALL;
257 void mm_open_all(void)
259 InitElementProperties_MM();