X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Ftape.c;h=44bbc57bcbe440274f30575c61e5f462207c19ce;hb=efd0d0abb853018aa3ccc3c727b39bd7f5ba679d;hp=7add692b51d605ad0bd07b50b8a276f09e89e6a4;hpb=49221e59bff18cdfbef8c877b588280266ae5037;p=rocksndiamonds.git diff --git a/src/tape.c b/src/tape.c index 7add692b..44bbc57b 100644 --- a/src/tape.c +++ b/src/tape.c @@ -1,14 +1,14 @@ /*********************************************************** -* Rocks'n'Diamonds -- McDuffin Strikes Back! * +* Rocks'n'Diamonds -- McDuffin Strikes Back! * *----------------------------------------------------------* -* (c) 1995-98 Artsoft Entertainment * -* Holger Schemel * -* Oststrasse 11a * -* 33604 Bielefeld * -* phone: ++49 +521 290471 * -* email: aeglos@valinor.owl.de * +* (c) 1995-2001 Artsoft Entertainment * +* Holger Schemel * +* Detmolder Strasse 189 * +* 33604 Bielefeld * +* Germany * +* e-mail: info@artsoft.org * *----------------------------------------------------------* -* tape.c * +* tape.c * ***********************************************************/ #include "libgame/libgame.h" @@ -18,6 +18,7 @@ #include "tools.h" #include "files.h" #include "network.h" +#include "cartoons.h" /* tape button identifiers */ #define TAPE_CTRL_ID_EJECT 0 @@ -77,7 +78,7 @@ static struct GadgetInfo *tape_gadget[NUM_TAPE_BUTTONS]; #define VIDEO_TIME_YSIZE 16 /* special */ -#define VIDEO_PBEND_LABEL_XPOS 6 +#define VIDEO_PBEND_LABEL_XPOS 5 #define VIDEO_PBEND_LABEL_YPOS 220 #define VIDEO_PBEND_LABEL_XSIZE 35 #define VIDEO_PBEND_LABEL_YSIZE 30 @@ -315,13 +316,17 @@ void TapeStartRecording() void TapeStopRecording() { +#if 0 int i; +#endif if (!tape.recording) return; +#if 0 for(i=0; i= MAX_TAPELEN-1) + { + TapeStopRecording(); + return; + } + + if (tape.pos[tape.counter].delay > 0) /* already stored action */ + { + boolean changed_events = FALSE; + + for(i=0; i= 255) + { + tape.counter++; + tape.pos[tape.counter].delay = 0; + } + else + tape.pos[tape.counter].delay++; + } + + if (tape.pos[tape.counter].delay == 0) /* store new action */ + { + for(i=0; i tape.length_seconds - TAPE_PAUSE_SECONDS_BEFORE_DEATH) + { + TapeTogglePause(); + return NULL; + } + } + + if (tape.counter >= tape.length) + { + TapeStop(); + return NULL; + } + + for(i=0; i= tape.pos[tape.counter].delay) + { + tape.counter++; + tape.delay_played = 0; + } + + return action; +} +#endif + +#if 0 boolean TapePlayDelay() { if (!tape.playing || tape.pausing) @@ -494,6 +599,14 @@ boolean TapePlayDelay() return(FALSE); } +#else + +boolean TapePlayDelay() +{ + return TRUE|FALSE; /* ...it doesn't matter at all */ +} +#endif + void TapeStop() { TapeStopRecording(); @@ -580,7 +693,7 @@ void CreateTapeButtons() for (i=0; i