projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
removed support for non-renderer graphics for SDL2 target
[rocksndiamonds.git]
/
src
/
libgame
/
toons.c
diff --git
a/src/libgame/toons.c
b/src/libgame/toons.c
index c9bf81ccf0eb54d3de8dd65cb6c53e941173f02a..34fa8fbb675f157256375535116f9938538f239e 100644
(file)
--- a/
src/libgame/toons.c
+++ b/
src/libgame/toons.c
@@
-13,12
+13,6
@@
#include "misc.h"
#include "misc.h"
-/* values for toon animation */
-#define ANIM_START 0
-#define ANIM_CONTINUE 1
-#define ANIM_STOP 2
-
-
static struct ToonScreenInfo screen_info;
static struct ToonScreenInfo screen_info;
@@
-159,6
+153,9
@@
void DrawAnim(Bitmap *toon_bitmap, int src_x, int src_y, int width, int height,
BlitBitmap(screen_info.save_buffer, backbuffer, buffer_x, buffer_y,
pad_width, pad_height, pad_dest_x, pad_dest_y);
BlitBitmap(screen_info.save_buffer, backbuffer, buffer_x, buffer_y,
pad_width, pad_height, pad_dest_x, pad_dest_y);
+
+ /* prevent immediate redraw of restored toon area in backbuffer */
+ redraw_mask = REDRAW_NONE;
}
boolean AnimateToon(int toon_nr, boolean restart)
}
boolean AnimateToon(int toon_nr, boolean restart)
@@
-352,7
+349,7
@@
void HandleAnimation(int mode)
case ANIM_STOP:
if (anim_running)
{
case ANIM_STOP:
if (anim_running)
{
- redraw_mask |=
(REDRAW_FIELD | REDRAW_FROM_BACKBUFFER)
;
+ redraw_mask |=
REDRAW_FIELD
;
screen_info.update_function();
screen_info.update_function();
@@
-382,18
+379,3
@@
void HandleAnimation(int mode)
anim_restart = reset_delay = AnimateToon(toon_nr, anim_restart);
}
anim_restart = reset_delay = AnimateToon(toon_nr, anim_restart);
}
-
-void InitAnimation()
-{
- HandleAnimation(ANIM_START);
-}
-
-void StopAnimation()
-{
- HandleAnimation(ANIM_STOP);
-}
-
-void DoAnimation()
-{
- HandleAnimation(ANIM_CONTINUE);
-}