Back to index

freedink-data  1.08.20080920
S2-FGATE.c
Go to the documentation of this file.
00001 void main(void)
00002 {
00003 sp_nodraw(&current_sprite, 1);
00004 sp_touch_damage(&current_sprite, -1);
00005 int &myx;
00006 int &myy;
00007 int &rcrap;
00008 int &mcrap;
00009 int &dcrap;
00010 &temp1hold = 0;
00011 }
00012 
00013 
00014  void touch (void)
00015  {
00016 
00017 if (&temp1hold != 0)
00018  return;
00019 sp_touch_damage(&current_sprite, 0);
00020 playsound(42, 10000, 0, 0, 0);
00021 playsound(15, 22000, 0, 0, 0);
00022 &life -= 5;
00023 &myx = sp_x(1,-1);
00024 &myy = sp_y(1,-1);
00025 &myy -= 60;
00026 &mcrap = create_sprite(&myx, &myy, 6, 169, 1);
00027 sp_seq(&mcrap, 169);
00028 
00029 &myy -= 30;
00030 &myx -= 30;
00031 &dcrap = create_sprite(&myx, &myy, 6, 169, 3);
00032 sp_seq(&dcrap, 169);
00033 sp_frame(&dcrap, 3);
00034 
00035 &myy += 10;
00036 &myx += 60;
00037 &rcrap = create_sprite(&myx, &myy, 6, 169, 6);
00038 sp_seq(&rcrap, 169);
00039 sp_frame(&rcrap, 6);
00040   say("Ouch!",1);
00041 
00042 
00043 if (&life < 1)
00044  {
00045  return;
00046  } else
00047  {
00048   move_stop(1, 2, 170, 1);
00049   
00050 sp_touch_damage(&current_sprite, -1);
00051   }
00052 sp_kill(&mcrap, 1500);
00053 sp_kill(&dcrap, 1500);
00054 sp_kill(&rcrap, 1500);
00055 
00056 wait(1000);
00057 sp_brain_parm(&mcrap, 40);
00058 sp_brain(&mcrap, 12);
00059 sp_brain_parm(&dcrap, 40);
00060 sp_brain(&dcrap, 12);
00061 sp_brain_parm(&rcrap, 40);
00062 sp_brain(&rcrap, 12);
00063 
00064 
00065 
00066  }