projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
rnd-20050424-1-src
[rocksndiamonds.git]
/
src
/
game_em
/
synchro_1.c
diff --git
a/src/game_em/synchro_1.c
b/src/game_em/synchro_1.c
index 5107c0ffa300d4338261399931b0f8a1cc7ced92..c5b2c456b4910ed38eae9452f42b29d4f17d1edb 100644
(file)
--- a/
src/game_em/synchro_1.c
+++ b/
src/game_em/synchro_1.c
@@
-88,8
+88,13
@@
static boolean player_killed(struct PLAYER *ply)
if (!ply->alive)
return FALSE;
if (!ply->alive)
return FALSE;
- if (lev.time_initial > 0 && lev.time == 0)
+#if 1
+ if (lev.killed_out_of_time && setup.time_limit)
+ return TRUE;
+#else
+ if (lev.time_initial > 0 && lev.time == 0 && setup.time_limit)
return TRUE;
return TRUE;
+#endif
switch(Cave[y-1][x])
{
switch(Cave[y-1][x])
{
@@
-337,7
+342,7
@@
static void kill_player(struct PLAYER *ply)
case Xexit_1:
case Xexit_2:
case Xexit_3:
case Xexit_1:
case Xexit_2:
case Xexit_3:
- play_element_sound(x, y, SAMPLE_exit, Xexit_1);
+ play_element_sound(x, y, SAMPLE_exit
_leave
, Xexit_1);
break;
default:
break;
default:
@@
-580,7
+585,7
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
Cave[y-1][x+1] = Yacid_splash_eB;
if (Cave[y-1][x-1] == Xblank)
Cave[y-1][x-1] = Yacid_splash_wB;
Cave[y-1][x+1] = Yacid_splash_eB;
if (Cave[y-1][x-1] == Xblank)
Cave[y-1][x-1] = Yacid_splash_wB;
- play_
sound(x, y, SAMPLE_acid
);
+ play_
element_sound(x, y, SAMPLE_acid, Xacid_1
);
case Xboom_android:
case Xboom_1:
case Xboom_android:
case Xboom_1:
@@
-760,7
+765,7
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
- play_
sound(x, y, SAMPLE_acid
);
+ play_
element_sound(x, y, SAMPLE_acid, Xacid_1
);
goto stone_walk;
case Xblank:
goto stone_walk;
case Xblank:
@@
-798,7
+803,7
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
- play_
sound(x, y, SAMPLE_acid
);
+ play_
element_sound(x, y, SAMPLE_acid, Xacid_1
);
goto bomb_walk;
case Xblank:
goto bomb_walk;
case Xblank:
@@
-836,7
+841,7
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
- play_
sound(x, y, SAMPLE_acid
);
+ play_
element_sound(x, y, SAMPLE_acid, Xacid_1
);
goto nut_walk;
case Xblank:
goto nut_walk;
case Xblank:
@@
-885,7
+890,7
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
Cave[y-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y-1][x+dx-1] == Xblank)
Cave[y-1][x+dx-1] = Yacid_splash_wB;
- play_
sound(x, y, SAMPLE_acid
);
+ play_
element_sound(x, y, SAMPLE_acid, Xacid_1
);
goto spring_walk;
case Xblank:
goto spring_walk;
case Xblank:
@@
-933,7
+938,7
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
Cave[y+dy-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y+dy-1][x+dx-1] == Xblank)
Cave[y+dy-1][x+dx-1] = Yacid_splash_wB;
Cave[y+dy-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y+dy-1][x+dx-1] == Xblank)
Cave[y+dy-1][x+dx-1] = Yacid_splash_wB;
- play_
sound(x, y, SAMPLE_acid
);
+ play_
element_sound(x, y, SAMPLE_acid, Xacid_1
);
goto balloon_walk;
case Xblank:
goto balloon_walk;
case Xblank:
@@
-978,7
+983,7
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
Cave[y+dy-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y+dy-1][x+dx-1] == Xblank)
Cave[y+dy-1][x+dx-1] = Yacid_splash_wB;
Cave[y+dy-1][x+dx+1] = Yacid_splash_eB;
if (Cave[y+dy-1][x+dx-1] == Xblank)
Cave[y+dy-1][x+dx-1] = Yacid_splash_wB;
- play_
sound(x, y, SAMPLE_acid
);
+ play_
element_sound(x, y, SAMPLE_acid, Xacid_1
);
goto android_walk;
case Xblank:
goto android_walk;
case Xblank:
@@
-1124,10
+1129,15
@@
static boolean player_digfield(struct PLAYER *ply, int dx, int dy)
case Xexit_1:
case Xexit_2:
case Xexit_3:
case Xexit_1:
case Xexit_2:
case Xexit_3:
- play_element_sound(x, y, SAMPLE_exit, Xexit_1);
+ play_element_sound(x, y, SAMPLE_exit
_leave
, Xexit_1);
- if (--lev.home == 0 && lev.time_initial > 0) /* game won */
+ lev.home--;
+
+#if 0
+ /* !!! CHECK SCORE CALCULATION !!! */
+ if (lev.home == 0 && lev.time_initial > 0) /* game won */
lev.score += lev.time * lev.exit_score / 100;
lev.score += lev.time * lev.exit_score / 100;
+#endif
ply->anim = SPR_walk + anim;
ply->x = x;
ply->anim = SPR_walk + anim;
ply->x = x;