?login_element?

Subversion Repositories NedoOS

Rev

Rev 954 | Blame | Compare with Previous | Last modification | View Log | Download

  1. #ifndef MENU_C
  2. #define MENU_C
  3. #include <evo.h>
  4. #include "gameloop.c"
  5. #include "engine.c"
  6. #include "font.c"
  7.  
  8. void instruction_page();
  9.  
  10. void menu_loop();
  11.  
  12. void init_menu_loop()
  13. {
  14.     music_play(MUS_EA2);
  15.     instruction_page();
  16.     menu_loop();
  17. }
  18.  
  19. void instruction_page()
  20. {
  21.     init_text();
  22.     text_x = 5;
  23.     text_y = 0;
  24.     put_str("Lost donation box incident\n\n");
  25.     put_str("Code and levels by Nihirash\nGraphics by Hina\nMusic by EA, WBCBZ7, Scalesmann, Gogin,\nNihirash\n\n");
  26.     text_x = 5;
  27.     put_str("Spring begins with an incident!");
  28.     put_str("\n\nReimu lost her donation box, right \nbefore the spring festival of flowers.\nTogether with the box, Aun Komano also \ndisappeared.");
  29.     put_str("\n\nNow she want to get them back!\n\n");
  30.     text_x = 2;
  31.     put_str("Pick up ");
  32.     put_char(128);
  33.     put_str(" - for power up your shoots\n");
  34.     text_x = 2;
  35.     put_str("Pick up ");
  36.     put_char(129);
  37.     put_str(" - to increase your \n\n");
  38.     text_x = 10;
  39.     put_str("Controls:\n\n");
  40.     //put_str("  ARROWS - movement\n  SPACE - fire\n\n\n\n");
  41.     put_str("  ARROWS - movement\n  SPACE - fire\n\n");
  42.     text_x = 7;
  43.     put_str("Press FIRE to start game!\n\n");
  44.     pal_bright(BRIGHT_MID);
  45.     swap_screen();
  46. }
  47.  
  48. void menu_loop()
  49. {
  50.     while (TRUE)
  51.     {
  52.         keyboard(keys);
  53.         if (keys[FIRE])
  54.             break;
  55.         vsync();//swap_screen();
  56.     }
  57.  
  58.     state = STATE_PLAY;
  59. }
  60.  
  61. #endif