projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
removed functions for correcting playfield buffer position for EM engine
[rocksndiamonds.git]
/
src
/
tape.c
diff --git
a/src/tape.c
b/src/tape.c
index bf24b531d24b9adbdd6679012689ddb3a12f7f51..f064f6cbb26b01e6808dbe42a8ec45fdf110aa72 100644
(file)
--- a/
src/tape.c
+++ b/
src/tape.c
@@
-547,7
+547,9
@@
void TapeErase(void)
tape.centered_player_nr_next = -1;
tape.set_centered_player = FALSE;
tape.centered_player_nr_next = -1;
tape.set_centered_player = FALSE;
- tape.use_mouse = (level.game_engine_type == GAME_ENGINE_TYPE_MM);
+ // set flags for game actions to default values (may be overwritten later)
+ tape.use_key_actions = TRUE;
+ tape.use_mouse_actions = FALSE;
}
static void TapeRewind(void)
}
static void TapeRewind(void)
@@
-660,7
+662,7
@@
void TapeStopRecording(void)
MapTapeEjectButton();
}
MapTapeEjectButton();
}
-boolean TapeAddAction(byte action[MAX_
PLAYER
S])
+boolean TapeAddAction(byte action[MAX_
TAPE_ACTION
S])
{
int i;
{
int i;
@@
-668,7
+670,7
@@
boolean TapeAddAction(byte action[MAX_PLAYERS])
{
boolean changed_events = FALSE;
{
boolean changed_events = FALSE;
- for (i = 0; i < MAX_
PLAYER
S; i++)
+ for (i = 0; i < MAX_
TAPE_ACTION
S; i++)
if (tape.pos[tape.counter].action[i] != action[i])
changed_events = TRUE;
if (tape.pos[tape.counter].action[i] != action[i])
changed_events = TRUE;
@@
-686,7
+688,7
@@
boolean TapeAddAction(byte action[MAX_PLAYERS])
if (tape.pos[tape.counter].delay == 0) // store new action
{
if (tape.pos[tape.counter].delay == 0) // store new action
{
- for (i = 0; i < MAX_
PLAYER
S; i++)
+ for (i = 0; i < MAX_
TAPE_ACTION
S; i++)
tape.pos[tape.counter].action[i] = action[i];
tape.pos[tape.counter].delay++;
tape.pos[tape.counter].action[i] = action[i];
tape.pos[tape.counter].delay++;
@@
-695,18
+697,18
@@
boolean TapeAddAction(byte action[MAX_PLAYERS])
return TRUE;
}
return TRUE;
}
-void TapeRecordAction(byte action_raw[MAX_
PLAYER
S])
+void TapeRecordAction(byte action_raw[MAX_
TAPE_ACTION
S])
{
{
- byte action[MAX_
PLAYER
S];
+ byte action[MAX_
TAPE_ACTION
S];
int i;
if (!tape.recording) // (record action even when tape is paused)
return;
int i;
if (!tape.recording) // (record action even when tape is paused)
return;
- for (i = 0; i < MAX_
PLAYER
S; i++)
+ for (i = 0; i < MAX_
TAPE_ACTION
S; i++)
action[i] = action_raw[i];
action[i] = action_raw[i];
- if (
!tape.use_mouse
&& tape.set_centered_player)
+ if (
tape.use_key_actions
&& tape.set_centered_player)
{
for (i = 0; i < MAX_PLAYERS; i++)
if (tape.centered_player_nr_next == i ||
{
for (i = 0; i < MAX_PLAYERS; i++)
if (tape.centered_player_nr_next == i ||
@@
-825,7
+827,7
@@
byte *TapePlayAction(void)
int update_delay = FRAMES_PER_SECOND / 2;
boolean update_video_display = (FrameCounter % update_delay == 0);
boolean update_draw_label_on = ((FrameCounter / update_delay) % 2 == 1);
int update_delay = FRAMES_PER_SECOND / 2;
boolean update_video_display = (FrameCounter % update_delay == 0);
boolean update_draw_label_on = ((FrameCounter / update_delay) % 2 == 1);
- static byte action[MAX_
PLAYER
S];
+ static byte action[MAX_
TAPE_ACTION
S];
int i;
if (!tape.playing || tape.pausing)
int i;
if (!tape.playing || tape.pausing)
@@
-874,12
+876,12
@@
byte *TapePlayAction(void)
DrawVideoDisplaySymbol(state);
}
DrawVideoDisplaySymbol(state);
}
- for (i = 0; i < MAX_
PLAYER
S; i++)
+ for (i = 0; i < MAX_
TAPE_ACTION
S; i++)
action[i] = tape.pos[tape.counter].action[i];
#if DEBUG_TAPE_WHEN_PLAYING
printf("%05d", FrameCounter);
action[i] = tape.pos[tape.counter].action[i];
#if DEBUG_TAPE_WHEN_PLAYING
printf("%05d", FrameCounter);
- for (i = 0; i < MAX_
PLAYER
S; i++)
+ for (i = 0; i < MAX_
TAPE_ACTION
S; i++)
printf(" %08x", action[i]);
printf("\n");
#endif
printf(" %08x", action[i]);
printf("\n");
#endif
@@
-887,7
+889,7
@@
byte *TapePlayAction(void)
tape.set_centered_player = FALSE;
tape.centered_player_nr_next = -999;
tape.set_centered_player = FALSE;
tape.centered_player_nr_next = -999;
- if (
!tape.use_mouse
)
+ if (
tape.use_key_actions
)
{
for (i = 0; i < MAX_PLAYERS; i++)
{
{
for (i = 0; i < MAX_PLAYERS; i++)
{