From: Holger Schemel Date: Sat, 15 Feb 2020 16:57:08 +0000 (+0100) Subject: added pushed objects going into acid (with compile time option) X-Git-Tag: 4.2.0.0~115 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=f717d0c1;p=rocksndiamonds.git added pushed objects going into acid (with compile time option) --- diff --git a/src/game_em/logic.c b/src/game_em/logic.c index ae3a9541..e149fc6f 100644 --- a/src/game_em/logic.c +++ b/src/game_em/logic.c @@ -9,6 +9,8 @@ #define SPRING_ROLL /* spring rolling off round things continues to roll */ +#define ACID_ROLL /* rolling objects go into acid rather than remove it */ + #define USE_CHANGED_ACID_STUFF #define RANDOM_RAW (seed = seed << 31 | seed >> 1) @@ -5577,6 +5579,25 @@ static void Lpush_emerald_e(int x, int y) next[x][y] = Xemerald; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Yemerald_eB; + next[x][y] = Xblank; + if (cave[x+2][y-1] == Xblank) + cave[x+2][y-1] = Xsplash_e; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Yemerald_eB; next[x][y] = Xblank; @@ -5602,6 +5623,25 @@ static void Lpush_emerald_w(int x, int y) next[x][y] = Xemerald; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Yemerald_wB; + next[x][y] = Xblank; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_e; + if (cave[x-2][y-1] == Xblank) + cave[x-2][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Yemerald_wB; next[x][y] = Xblank; @@ -5627,6 +5667,25 @@ static void Lpush_diamond_e(int x, int y) next[x][y] = Xdiamond; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ydiamond_eB; + next[x][y] = Xblank; + if (cave[x+2][y-1] == Xblank) + cave[x+2][y-1] = Xsplash_e; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ydiamond_eB; next[x][y] = Xblank; @@ -5652,6 +5711,25 @@ static void Lpush_diamond_w(int x, int y) next[x][y] = Xdiamond; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ydiamond_wB; + next[x][y] = Xblank; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_e; + if (cave[x-2][y-1] == Xblank) + cave[x-2][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ydiamond_wB; next[x][y] = Xblank; @@ -5677,6 +5755,25 @@ static void Lpush_stone_e(int x, int y) next[x][y] = Xstone; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ystone_eB; + next[x][y] = Xblank; + if (cave[x+2][y-1] == Xblank) + cave[x+2][y-1] = Xsplash_e; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ystone_eB; next[x][y] = Xblank; @@ -5702,6 +5799,25 @@ static void Lpush_stone_w(int x, int y) next[x][y] = Xstone; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ystone_wB; + next[x][y] = Xblank; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_e; + if (cave[x-2][y-1] == Xblank) + cave[x-2][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ystone_wB; next[x][y] = Xblank; @@ -5727,6 +5843,25 @@ static void Lpush_bomb_e(int x, int y) next[x][y] = Xbomb; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ybomb_eB; + next[x][y] = Xblank; + if (cave[x+2][y-1] == Xblank) + cave[x+2][y-1] = Xsplash_e; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ybomb_eB; next[x][y] = Xblank; @@ -5752,6 +5887,25 @@ static void Lpush_bomb_w(int x, int y) next[x][y] = Xbomb; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ybomb_wB; + next[x][y] = Xblank; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_e; + if (cave[x-2][y-1] == Xblank) + cave[x-2][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ybomb_wB; next[x][y] = Xblank; @@ -5777,6 +5931,25 @@ static void Lpush_nut_e(int x, int y) next[x][y] = Xnut; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ynut_eB; + next[x][y] = Xblank; + if (cave[x+2][y-1] == Xblank) + cave[x+2][y-1] = Xsplash_e; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ynut_eB; next[x][y] = Xblank; @@ -5802,6 +5975,25 @@ static void Lpush_nut_w(int x, int y) next[x][y] = Xnut; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Ynut_wB; + next[x][y] = Xblank; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_e; + if (cave[x-2][y-1] == Xblank) + cave[x-2][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Ynut_wB; next[x][y] = Xblank; @@ -5827,6 +6019,25 @@ static void Lpush_spring_e(int x, int y) next[x][y] = Xspring; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Yspring_eB; + next[x][y] = Xblank; + if (cave[x+2][y-1] == Xblank) + cave[x+2][y-1] = Xsplash_e; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Yspring_eB; next[x][y] = Xblank; @@ -5852,6 +6063,25 @@ static void Lpush_spring_w(int x, int y) next[x][y] = Xspring; return; +#ifdef ACID_ROLL + case Xacid_1: + case Xacid_2: + case Xacid_3: + case Xacid_4: + case Xacid_5: + case Xacid_6: + case Xacid_7: + case Xacid_8: + cave[x][y] = Yspring_wB; + next[x][y] = Xblank; + if (cave[x][y-1] == Xblank) + cave[x][y-1] = Xsplash_e; + if (cave[x-2][y-1] == Xblank) + cave[x-2][y-1] = Xsplash_w; + play_element_sound(x, y, SOUND_acid, Xacid_1); + return; +#endif + default: cave[x][y] = Yspring_wB; next[x][y] = Xblank;