* fixed a very nasty bug in dragon turning code in TurnRoundExt()
(that only showed up on Linux, but not on Windows systems)
* fixed turning movement of butterflies and fireflies (no frame reset)
* enhanced sniksnak turning movement (two steps instead of only one)
* Version number set to 3.0.8.
* Version 3.0.7 released.
+Release Version 3.0.8 [?? ??? ????]
+-----------------------------------
+
Release Version 3.0.7 [10 NOV 2003]
-----------------------------------
- fixed incorrectly displayed animation for attacking dragon
Release Version 3.0.7 [10 NOV 2003]
-----------------------------------
- fixed incorrectly displayed animation for attacking dragon
+2003-11-14
+ * fixed a very nasty bug in dragon turning code in TurnRoundExt()
+ (that only showed up on Linux, but not on Windows systems)
+
+2003-11-13
+ * fixed turning movement of butterflies and fireflies (no frame reset)
+ * enhanced sniksnak turning movement (two steps instead of only one)
+
+2003-11-10
+ * Version number set to 3.0.8.
+
+2003-11-10
+ * Version 3.0.7 released.
+
2003-11-09
* fixed reset of player animation frame when, for example,
walking, digging or collecting share the same animation
2003-11-09
* fixed reset of player animation frame when, for example,
walking, digging or collecting share the same animation
{ "bd_butterfly.frames", "2" },
{ "bd_butterfly.anim_mode", "pingpong" },
{ "bd_butterfly.delay", "4" },
{ "bd_butterfly.frames", "2" },
{ "bd_butterfly.anim_mode", "pingpong" },
{ "bd_butterfly.delay", "4" },
+ { "bd_butterfly.global_sync", "true" },
{ "bd_butterfly.right", "RocksElements.pcx" },
{ "bd_butterfly.right.xpos", "4" },
{ "bd_butterfly.right.ypos", "12" },
{ "bd_butterfly.right.frames", "2" },
{ "bd_butterfly.right.anim_mode", "pingpong" },
{ "bd_butterfly.right.delay", "4" },
{ "bd_butterfly.right", "RocksElements.pcx" },
{ "bd_butterfly.right.xpos", "4" },
{ "bd_butterfly.right.ypos", "12" },
{ "bd_butterfly.right.frames", "2" },
{ "bd_butterfly.right.anim_mode", "pingpong" },
{ "bd_butterfly.right.delay", "4" },
+ { "bd_butterfly.right.global_sync", "true" },
{ "bd_butterfly.right.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.right.EDITOR.xpos", "8" },
{ "bd_butterfly.right.EDITOR.ypos", "12" },
{ "bd_butterfly.right.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.right.EDITOR.xpos", "8" },
{ "bd_butterfly.right.EDITOR.ypos", "12" },
{ "bd_butterfly.up.frames", "2" },
{ "bd_butterfly.up.anim_mode", "pingpong" },
{ "bd_butterfly.up.delay", "4" },
{ "bd_butterfly.up.frames", "2" },
{ "bd_butterfly.up.anim_mode", "pingpong" },
{ "bd_butterfly.up.delay", "4" },
+ { "bd_butterfly.up.global_sync", "true" },
{ "bd_butterfly.up.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.up.EDITOR.xpos", "9" },
{ "bd_butterfly.up.EDITOR.ypos", "12" },
{ "bd_butterfly.up.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.up.EDITOR.xpos", "9" },
{ "bd_butterfly.up.EDITOR.ypos", "12" },
{ "bd_butterfly.left.frames", "2" },
{ "bd_butterfly.left.anim_mode", "pingpong" },
{ "bd_butterfly.left.delay", "4" },
{ "bd_butterfly.left.frames", "2" },
{ "bd_butterfly.left.anim_mode", "pingpong" },
{ "bd_butterfly.left.delay", "4" },
+ { "bd_butterfly.left.global_sync", "true" },
{ "bd_butterfly.left.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.left.EDITOR.xpos", "10" },
{ "bd_butterfly.left.EDITOR.ypos", "12" },
{ "bd_butterfly.left.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.left.EDITOR.xpos", "10" },
{ "bd_butterfly.left.EDITOR.ypos", "12" },
{ "bd_butterfly.down.frames", "2" },
{ "bd_butterfly.down.anim_mode", "pingpong" },
{ "bd_butterfly.down.delay", "4" },
{ "bd_butterfly.down.frames", "2" },
{ "bd_butterfly.down.anim_mode", "pingpong" },
{ "bd_butterfly.down.delay", "4" },
+ { "bd_butterfly.down.global_sync", "true" },
{ "bd_butterfly.down.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.down.EDITOR.xpos", "11" },
{ "bd_butterfly.down.EDITOR.ypos", "12" },
{ "bd_butterfly.down.EDITOR", "RocksElements.pcx" },
{ "bd_butterfly.down.EDITOR.xpos", "11" },
{ "bd_butterfly.down.EDITOR.ypos", "12" },
{ "bd_firefly.frames", "2" },
{ "bd_firefly.anim_mode", "pingpong" },
{ "bd_firefly.delay", "4" },
{ "bd_firefly.frames", "2" },
{ "bd_firefly.anim_mode", "pingpong" },
{ "bd_firefly.delay", "4" },
+ { "bd_firefly.global_sync", "true" },
{ "bd_firefly.right", "RocksElements.pcx" },
{ "bd_firefly.right.xpos", "6" },
{ "bd_firefly.right.ypos", "12" },
{ "bd_firefly.right.frames", "2" },
{ "bd_firefly.right.anim_mode", "pingpong" },
{ "bd_firefly.right.delay", "4" },
{ "bd_firefly.right", "RocksElements.pcx" },
{ "bd_firefly.right.xpos", "6" },
{ "bd_firefly.right.ypos", "12" },
{ "bd_firefly.right.frames", "2" },
{ "bd_firefly.right.anim_mode", "pingpong" },
{ "bd_firefly.right.delay", "4" },
+ { "bd_firefly.right.global_sync", "true" },
{ "bd_firefly.right.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.right.EDITOR.xpos", "12" },
{ "bd_firefly.right.EDITOR.ypos", "12" },
{ "bd_firefly.right.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.right.EDITOR.xpos", "12" },
{ "bd_firefly.right.EDITOR.ypos", "12" },
{ "bd_firefly.up.frames", "2" },
{ "bd_firefly.up.anim_mode", "pingpong" },
{ "bd_firefly.up.delay", "4" },
{ "bd_firefly.up.frames", "2" },
{ "bd_firefly.up.anim_mode", "pingpong" },
{ "bd_firefly.up.delay", "4" },
+ { "bd_firefly.up.global_sync", "true" },
{ "bd_firefly.up.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.up.EDITOR.xpos", "13" },
{ "bd_firefly.up.EDITOR.ypos", "12" },
{ "bd_firefly.up.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.up.EDITOR.xpos", "13" },
{ "bd_firefly.up.EDITOR.ypos", "12" },
{ "bd_firefly.left.frames", "2" },
{ "bd_firefly.left.anim_mode", "pingpong" },
{ "bd_firefly.left.delay", "4" },
{ "bd_firefly.left.frames", "2" },
{ "bd_firefly.left.anim_mode", "pingpong" },
{ "bd_firefly.left.delay", "4" },
+ { "bd_firefly.left.global_sync", "true" },
{ "bd_firefly.left.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.left.EDITOR.xpos", "14" },
{ "bd_firefly.left.EDITOR.ypos", "12" },
{ "bd_firefly.left.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.left.EDITOR.xpos", "14" },
{ "bd_firefly.left.EDITOR.ypos", "12" },
{ "bd_firefly.down.frames", "2" },
{ "bd_firefly.down.anim_mode", "pingpong" },
{ "bd_firefly.down.delay", "4" },
{ "bd_firefly.down.frames", "2" },
{ "bd_firefly.down.anim_mode", "pingpong" },
{ "bd_firefly.down.delay", "4" },
+ { "bd_firefly.down.global_sync", "true" },
{ "bd_firefly.down.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.down.EDITOR.xpos", "15" },
{ "bd_firefly.down.EDITOR.ypos", "12" },
{ "bd_firefly.down.EDITOR", "RocksElements.pcx" },
{ "bd_firefly.down.EDITOR.xpos", "15" },
{ "bd_firefly.down.EDITOR.ypos", "12" },
{ "sp_sniksnak.turning_from_left.up", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_left.up.xpos", "12" },
{ "sp_sniksnak.turning_from_left.up.ypos", "6" },
{ "sp_sniksnak.turning_from_left.up", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_left.up.xpos", "12" },
{ "sp_sniksnak.turning_from_left.up.ypos", "6" },
- { "sp_sniksnak.turning_from_left.up.frames", "1" },
+ { "sp_sniksnak.turning_from_left.up.frames", "2" },
+ { "sp_sniksnak.turning_from_left.up.delay", "4" },
+ { "sp_sniksnak.turning_from_left.up.offset", "1408" },
+ { "sp_sniksnak.turning_from_left.up.anim_mode","linear" },
{ "sp_sniksnak.turning_from_left.down", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_left.down.xpos", "13" },
{ "sp_sniksnak.turning_from_left.down.ypos", "6" },
{ "sp_sniksnak.turning_from_left.down", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_left.down.xpos", "13" },
{ "sp_sniksnak.turning_from_left.down.ypos", "6" },
- { "sp_sniksnak.turning_from_left.down.frames","1" },
+ { "sp_sniksnak.turning_from_left.down.frames","2" },
+ { "sp_sniksnak.turning_from_left.down.delay", "4" },
+ { "sp_sniksnak.turning_from_left.down.offset","1504" },
+ { "sp_sniksnak.turning_from_left.down.anim_mode","linear" },
{ "sp_sniksnak.turning_from_right.up", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_right.up.xpos", "15" },
{ "sp_sniksnak.turning_from_right.up.ypos", "6" },
{ "sp_sniksnak.turning_from_right.up", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_right.up.xpos", "15" },
{ "sp_sniksnak.turning_from_right.up.ypos", "6" },
- { "sp_sniksnak.turning_from_right.up.frames", "1" },
+ { "sp_sniksnak.turning_from_right.up.frames", "2" },
+ { "sp_sniksnak.turning_from_right.up.delay", "4" },
+ { "sp_sniksnak.turning_from_right.up.offset", "1312" },
+ { "sp_sniksnak.turning_from_right.up.anim_mode","linear" },
{ "sp_sniksnak.turning_from_right.down", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_right.down.xpos", "14" },
{ "sp_sniksnak.turning_from_right.down.ypos", "6" },
{ "sp_sniksnak.turning_from_right.down", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_right.down.xpos", "14" },
{ "sp_sniksnak.turning_from_right.down.ypos", "6" },
- { "sp_sniksnak.turning_from_right.down.frames","1" },
+ { "sp_sniksnak.turning_from_right.down.frames","2" },
+ { "sp_sniksnak.turning_from_right.down.delay","4" },
+ { "sp_sniksnak.turning_from_right.down.offset","1472" },
+ { "sp_sniksnak.turning_from_right.down.anim_mode","linear" },
{ "sp_sniksnak.turning_from_up.left", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_up.left.xpos", "12" },
{ "sp_sniksnak.turning_from_up.left.ypos", "6" },
{ "sp_sniksnak.turning_from_up.left", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_up.left.xpos", "12" },
{ "sp_sniksnak.turning_from_up.left.ypos", "6" },
- { "sp_sniksnak.turning_from_up.left.frames", "1" },
+ { "sp_sniksnak.turning_from_up.left.frames", "2" },
+ { "sp_sniksnak.turning_from_up.left.delay", "4" },
+ { "sp_sniksnak.turning_from_up.left.offset", "896" },
+ { "sp_sniksnak.turning_from_up.left.anim_mode","linear" },
{ "sp_sniksnak.turning_from_up.right", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_up.right.xpos", "15" },
{ "sp_sniksnak.turning_from_up.right.ypos", "6" },
{ "sp_sniksnak.turning_from_up.right", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_up.right.xpos", "15" },
{ "sp_sniksnak.turning_from_up.right.ypos", "6" },
- { "sp_sniksnak.turning_from_up.right.frames", "1" },
+ { "sp_sniksnak.turning_from_up.right.frames", "2" },
+ { "sp_sniksnak.turning_from_up.right.delay", "4" },
+ { "sp_sniksnak.turning_from_up.right.offset", "928" },
+ { "sp_sniksnak.turning_from_up.right.anim_mode","linear" },
{ "sp_sniksnak.turning_from_down.left", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_down.left.xpos", "13" },
{ "sp_sniksnak.turning_from_down.left.ypos", "6" },
{ "sp_sniksnak.turning_from_down.left", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_down.left.xpos", "13" },
{ "sp_sniksnak.turning_from_down.left.ypos", "6" },
- { "sp_sniksnak.turning_from_down.left.frames","1" },
+ { "sp_sniksnak.turning_from_down.left.frames","2" },
+ { "sp_sniksnak.turning_from_down.left.delay", "4" },
+ { "sp_sniksnak.turning_from_down.left.offset","864" },
+ { "sp_sniksnak.turning_from_down.left.anim_mode","linear" },
{ "sp_sniksnak.turning_from_down.right", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_down.right.xpos", "14" },
{ "sp_sniksnak.turning_from_down.right.ypos", "6" },
{ "sp_sniksnak.turning_from_down.right", "RocksSP.pcx" },
{ "sp_sniksnak.turning_from_down.right.xpos", "14" },
{ "sp_sniksnak.turning_from_down.right.ypos", "6" },
- { "sp_sniksnak.turning_from_down.right.frames","1" },
+ { "sp_sniksnak.turning_from_down.right.frames","2" },
+ { "sp_sniksnak.turning_from_down.right.delay","4" },
+ { "sp_sniksnak.turning_from_down.right.offset","960" },
+ { "sp_sniksnak.turning_from_down.right.anim_mode","linear" },
{ "sp_electron", "RocksSP.pcx" },
{ "sp_electron.xpos", "8" },
{ "sp_electron", "RocksSP.pcx" },
{ "sp_electron.xpos", "8" },
-#define COMPILE_DATE_STRING "[2003-11-10 02:01]"
+#define COMPILE_DATE_STRING "[2003-11-14 23:13]"
printf("Player %d %sactive.\n",
i + 1, (stored_player[i].active ? "" : "not "));
}
printf("Player %d %sactive.\n",
i + 1, (stored_player[i].active ? "" : "not "));
}
+
+#if 0
+ printf("::: starting game [%d]\n", FrameCounter);
+#endif
}
void InitMovDir(int x, int y)
}
void InitMovDir(int x, int y)
int rnd_value = 24;
int rnd = RND(rnd_value);
int rnd_value = 24;
int rnd = RND(rnd_value);
+#if 0
+ if (FrameCounter < 1 && x == 0 && y == 29)
+ printf(":2: %d/%d: %d [%d]\n", x, y, MovDir[x][y], FrameCounter);
+#endif
+
if (can_move_on && rnd > rnd_value / 8)
MovDir[x][y] = old_move_dir;
else if (can_turn_left && can_turn_right)
if (can_move_on && rnd > rnd_value / 8)
MovDir[x][y] = old_move_dir;
else if (can_turn_left && can_turn_right)
xx = x + move_xy[MovDir[x][y]].x;
yy = y + move_xy[MovDir[x][y]].y;
xx = x + move_xy[MovDir[x][y]].x;
yy = y + move_xy[MovDir[x][y]].y;
+#if 0
+ if (FrameCounter < 1 && x == 0 && y == 29)
+ printf(":3: %d/%d: %d (%d/%d: %d) [%d]\n", x, y, MovDir[x][y],
+ xx, yy, Feld[xx][yy],
+ FrameCounter);
+#endif
+
+#if 1
+ if (!IN_LEV_FIELD_AND_IS_FREE(xx, yy))
+ MovDir[x][y] = old_move_dir;
+#else
if (!IS_FREE(xx, yy))
MovDir[x][y] = old_move_dir;
if (!IS_FREE(xx, yy))
MovDir[x][y] = old_move_dir;
+#endif
+
+#if 0
+ if (FrameCounter < 1 && x == 0 && y == 29)
+ printf(":4: %d/%d: %d [%d]\n", x, y, MovDir[x][y], FrameCounter);
+#endif
+#if 0
+ if (FrameCounter < 1 && x == 0 && y == 29)
+ printf(":1: %d/%d: %d [%d]\n", x, y, MovDir[x][y], FrameCounter);
+#endif
+
if (!MovDelay[x][y]) /* start new movement phase */
{
/* all objects that can change their move direction after each step
if (!MovDelay[x][y]) /* start new movement phase */
{
/* all objects that can change their move direction after each step
+#if 0
+ if (FrameCounter < 1 && x == 0 && y == 29)
+ printf(":9: %d: %d [%d]\n", y, MovDir[x][y], FrameCounter);
+#endif
+
if (MovDelay[x][y] && (element == EL_BUG ||
element == EL_SPACESHIP ||
element == EL_SP_SNIKSNAK ||
if (MovDelay[x][y] && (element == EL_BUG ||
element == EL_SPACESHIP ||
element == EL_SP_SNIKSNAK ||
if (tape.pausing)
return;
if (tape.pausing)
return;
+#if 0
+ printf("::: getting new tape action [%d]\n", FrameCounter);
+#endif
+
recorded_player_action = (tape.playing ? TapePlayAction() : NULL);
for (i=0; i<MAX_PLAYERS; i++)
recorded_player_action = (tape.playing ? TapePlayAction() : NULL);
for (i=0; i<MAX_PLAYERS; i++)
return (unsigned int) seed;
}
return (unsigned int) seed;
}
unsigned int get_random_number(int nr, unsigned int max)
{
return (max > 0 ? random_linux_libc(nr) % max : 0);
}
unsigned int get_random_number(int nr, unsigned int max)
{
return (max > 0 ? random_linux_libc(nr) % max : 0);
}
+#else
+unsigned int get_random_number(int nr, unsigned int max)
+{
+ unsigned int rnd = (max > 0 ? random_linux_libc(nr) % max : 0);
+
+ if (nr == 0 && FrameCounter < 2)
+ printf("::: %d [%d]\n", rnd, FrameCounter);
+
+#if 0
+ if (nr == 0 && FrameCounter < 2 && rnd == 8)
+ rnd /= 0;
+#endif
+
+ return rnd;
+}
+#endif
/* ------------------------------------------------------------------------- */
/* ------------------------------------------------------------------------- */
{ ".emptying", ACTION_EMPTYING, FALSE },
{ ".changing", ACTION_CHANGING, FALSE },
{ ".exploding", ACTION_EXPLODING, FALSE },
{ ".emptying", ACTION_EMPTYING, FALSE },
{ ".changing", ACTION_CHANGING, FALSE },
{ ".exploding", ACTION_EXPLODING, FALSE },
+ { ".boring", ACTION_BORING, FALSE },
+ { ".sleeping", ACTION_SLEEPING, TRUE },
{ ".dying", ACTION_DYING, FALSE },
{ ".turning", ACTION_TURNING, FALSE },
{ ".turning_from_left", ACTION_TURNING_FROM_LEFT, FALSE },
{ ".dying", ACTION_DYING, FALSE },
{ ".turning", ACTION_TURNING, FALSE },
{ ".turning_from_left", ACTION_TURNING_FROM_LEFT, FALSE },
#define ACTION_EMPTYING 22
#define ACTION_CHANGING 23
#define ACTION_EXPLODING 24
#define ACTION_EMPTYING 22
#define ACTION_CHANGING 23
#define ACTION_EXPLODING 24
-#define ACTION_DYING 25
-#define ACTION_TURNING 26
-#define ACTION_TURNING_FROM_LEFT 27
-#define ACTION_TURNING_FROM_RIGHT 28
-#define ACTION_TURNING_FROM_UP 29
-#define ACTION_TURNING_FROM_DOWN 30
-#define ACTION_OTHER 31
-
-#define NUM_ACTIONS 32
+#define ACTION_BORING 25
+#define ACTION_SLEEPING 26
+#define ACTION_DYING 27
+#define ACTION_TURNING 28
+#define ACTION_TURNING_FROM_LEFT 29
+#define ACTION_TURNING_FROM_RIGHT 30
+#define ACTION_TURNING_FROM_UP 31
+#define ACTION_TURNING_FROM_DOWN 32
+#define ACTION_OTHER 33
+
+#define NUM_ACTIONS 34
/* values for special image configuration suffixes (must match game mode) */
#define GFX_SPECIAL_ARG_MAIN 0
/* values for special image configuration suffixes (must match game mode) */
#define GFX_SPECIAL_ARG_MAIN 0