projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
added configuration handling for global animations (yet to be implemented)
[rocksndiamonds.git]
/
src
/
tools.c
diff --git
a/src/tools.c
b/src/tools.c
index 0e030f7bb9da94839d8983af84c264c11f42054e..4d8222e023cf196310b65e0a25d3fba33b84814c 100644
(file)
--- a/
src/tools.c
+++ b/
src/tools.c
@@
-649,7
+649,7
@@
void FadeSetEnterScreen()
void FadeSetNextScreen()
{
void FadeSetNextScreen()
{
- fading = menu.next_screen;
+ fading = menu.next_screen
[game_status]
;
// (do not overwrite fade mode set by FadeSetEnterScreen)
// FadeSetLeaveNext(fading, TRUE); /* (keep same fade mode) */
// (do not overwrite fade mode set by FadeSetEnterScreen)
// FadeSetLeaveNext(fading, TRUE); /* (keep same fade mode) */
@@
-875,7
+875,8
@@
static void RedrawGlobalBorderIfNeeded()
return;
// copy current draw buffer to later copy back areas that have not changed
return;
// copy current draw buffer to later copy back areas that have not changed
- BlitBitmap(backbuffer, bitmap_db_store, 0, 0, WIN_XSIZE, WIN_YSIZE, 0, 0);
+ if (game_status_last != GAME_MODE_TITLE)
+ BlitBitmap(backbuffer, bitmap_db_store, 0, 0, WIN_XSIZE, WIN_YSIZE, 0, 0);
if (CheckIfGlobalBorderRedrawIsNeeded())
{
if (CheckIfGlobalBorderRedrawIsNeeded())
{
@@
-1064,8
+1065,8
@@
void getSizedGraphicSourceExt(int graphic, int frame, int tilesize,
}
*bitmap = src_bitmap;
}
*bitmap = src_bitmap;
- *x = src_x * tilesize /
TILESIZE
;
- *y = src_y * tilesize /
TILESIZE
;
+ *x = src_x * tilesize /
g->tile_size
;
+ *y = src_y * tilesize /
g->tile_size
;
}
void getFixedGraphicSourceExt(int graphic, int frame, Bitmap **bitmap,
}
void getFixedGraphicSourceExt(int graphic, int frame, Bitmap **bitmap,
@@
-1126,6
+1127,9
@@
inline static void getGraphicSourceExt(int graphic, int frame, Bitmap **bitmap,
*x = src_x + frame * g->offset_x;
*y = src_y + frame * g->offset_y;
}
*x = src_x + frame * g->offset_x;
*y = src_y + frame * g->offset_y;
}
+
+ *x = *x * TILESIZE_VAR / g->tile_size;
+ *y = *y * TILESIZE_VAR / g->tile_size;
}
void getGraphicSource(int graphic, int frame, Bitmap **bitmap, int *x, int *y)
}
void getGraphicSource(int graphic, int frame, Bitmap **bitmap, int *x, int *y)
@@
-1235,13
+1239,12
@@
void DrawGraphicThruMaskExt(DrawBuffer *d, int dst_x, int dst_y, int graphic,
void DrawFixedGraphicThruMaskExt(DrawBuffer *d, int dst_x, int dst_y,
int graphic, int frame)
{
void DrawFixedGraphicThruMaskExt(DrawBuffer *d, int dst_x, int dst_y,
int graphic, int frame)
{
- struct GraphicInfo *g = &graphic_info[graphic];
Bitmap *src_bitmap;
int src_x, src_y;
getFixedGraphicSource(graphic, frame, &src_bitmap, &src_x, &src_y);
Bitmap *src_bitmap;
int src_x, src_y;
getFixedGraphicSource(graphic, frame, &src_bitmap, &src_x, &src_y);
- BlitBitmapMasked(src_bitmap, d, src_x, src_y,
g->width, g->height
,
+ BlitBitmapMasked(src_bitmap, d, src_x, src_y,
TILEX, TILEY
,
dst_x, dst_y);
}
dst_x, dst_y);
}
@@
-2388,13
+2391,6
@@
void AnimateEnvelopeRequest(int anim_mode, int action)
ystart = yend;
end = 0;
}
ystart = yend;
end = 0;
}
- else
- {
- if (action == ACTION_OPENING)
- PlayMenuSoundStereo(SND_DOOR_OPENING, SOUND_MIDDLE);
- else if (action == ACTION_CLOSING)
- PlayMenuSoundStereo(SND_DOOR_CLOSING, SOUND_MIDDLE);
- }
for (i = start; i <= end; i++)
{
for (i = start; i <= end; i++)
{