let Selection = 1; let Page = 1; let Location = "Main"; let Music = true; let Items = 6; let TotalPages = 1; task MainMenu { Location = "Main"; Selection = 1; Items = 6; wait(10); loop { if(GetKeyState(VK_UP) == KEY_PUSH) { Selection--;} if(GetKeyState(VK_DOWN) == KEY_PUSH) { Selection++;} if(Selection > Items) { Selection = 1;} if(Selection < 1) { Selection = Items;} if(GetKeyState(VK_BOMB) == KEY_PUSH) { Selection = 6;} if(GetKeyState(BK_SHOT) == KEY_PUSH) { alternative (Selection) case(1) {Location = "Difficulty"; DifficultySelect;} //To Start The Game case(2) {Location = "ExDifficulty"; ExDifficultySelect;} //Not in the Demo case(3) {Location = "PrDifficulty"; PracticeSelect;} // To Practice Cleared Spellcards case(4) {Location = "SpellcardPractice"; SpellcardSelect;} // Not in the Demo case(5) {Location = "MusicRoom";} // To Listen Music. case(6) {ClearStage;} //To Exit the Game. } return; } yield; } task DifficultySelect { Items = 4; Selection = 1; Location "Difficulty"; wait(10); loop { if(GetKeyState(VK_UP) == KEY_PUSH) { Selection--;} if(GetKeyState(VK_DOWN) == KEY_PUSH) { Selection++;} if(Selection > Items) { Selection = 1;} if(Selection < 1) { Selection = Items;} if(GetKeyState(VK_BOMB) == KEY_PUSH) { MainMenu; Location = "Main";} if(GetKeyState(BK_SHOT) == KEY_PUSH) { alternative (Selection) case(1) {Location = "PlayerSelect"; SetCommonData("PlayLevel", 1);} // Easy case(2) {Location = "PlayerSelect"; SetCommonData("PlayLevel", 2);} // Normal case(3) {Location = "PlayerSelect"; SetCommonData("PlayLevel", 3);} // Hard case(4) {Location = "PlayerSelect"; SetCommonData("PlayLevel", 4);} // Lunatic } return; } yield; } task ExDifficultySelect { Items = 1; Selection = 1; Location "ExDifficulty"; wait(10); loop { if(GetKeyState(VK_UP) == KEY_PUSH) { Selection--;} if(GetKeyState(VK_DOWN) == KEY_PUSH) { Selection++;} if(Selection > Items) { Selection = 1;} if(Selection < 1) { Selection = Items;} if(GetKeyState(VK_BOMB) == KEY_PUSH) { MainMenu; Location = "Main";} if(GetKeyState(BK_SHOT) == KEY_PUSH) { alternative (Selection) case(1) {Location = "PlayerSelect"; SetCommonData("PlayLevel", 5);} // Extra } return; } yield; } task PracticeSelect { Items = 4; Selection = 1; Location "PrDifficulty"; wait(10); loop { if(GetKeyState(VK_UP) == KEY_PUSH) { Selection--;} if(GetKeyState(VK_DOWN) == KEY_PUSH) { Selection++;} if(Selection > Items) { Selection = 1;} if(Selection < 1) { Selection = Items;} if(GetKeyState(VK_BOMB) == KEY_PUSH) { MainMenu; Location = "Main";} if(GetKeyState(BK_SHOT) == KEY_PUSH) { alternative (Selection) case(1) {Location = "PrPlayerSelect"; SetCommonData("PlayLevel", 1);} case(2) {Location = "PrPlayerSelect"; SetCommonData("PlayLevel", 2);} case(3) {Location = "PrPlayerSelect"; SetCommonData("PlayLevel", 3);} case(4) {Location = "PrPlayerSelect"; SetCommonData("PlayLevel", 4);} } return; } yield; } task SpellcardSelect { Items = 10; TotalPages = 8; // Stage 1, Stage 2, Stage 3, Stage 4, Stage 5, Stage 6, Stage Extra, Focus Spellcards Page = 1; Selection = 1; Location = "SpellcardPractice"; wait(10); loop { if(GetKeyState(VK_UP) == KEY_PUSH) { Selection--;} if(GetKeyState(VK_DOWN) == KEY_PUSH) { Selection++;} if(GetKeyState(VK_LEFT) == KEY_PUSH) { Page--;} if(GetKeyState(VK_RIGHT) == KEY_PUSH) { Page++;} if(Selection > Items) { Selection = 1;} if(Selection < 1) { Selection = Items;} if(Page > TotalPages) { Page = 1;} if(Page < 1) { Page = TotalPages;} if(GetKeyState(VK_BOMB) == KEY_PUSH) { MainMenu; Location = "Main";} if(Page == 1) { if(GetKeyState(BK_SHOT) == KEY_PUSH) { alternative (Selection) case(1) {Spell 1} case(2) {Spell 2} case(3) {Spell 3} case(4) {Spell 4} case(5) {Spell 5} case(6) {Spell 6} case(7) {Spell 7} case(8) {Spell 8} case(9) {Spell 9} case(10) {Spell 10} } } if(Page == 2) { if(GetKeyState(BK_SHOT) == KEY_PUSH) { alternative (Selection) case(1) {Spell 1} case(2) {Spell 2} case(3) {Spell 3} case(4) {Spell 4} case(5) {Spell 5} case(6) {Spell 6} case(7) {Spell 7} case(8) {Spell 8} case(9) {Spell 9} case(10) {Spell 10} case(11) {Spell 11} case(12) {Spell 12} case(13) {Spell 13} case(14) {Spell 14} case(15) {Spell 15} case(16) {Spell 16} } } if(Page == 3) { if(GetKeyState(BK_SHOT) == KEY_PUSH) { alternative (Selection) case(1) {Spell 1} case(2) {Spell 2} case(3) {Spell 3} case(4) {Spell 4} case(5) {Spell 5} case(6) {Spell 6} case(7) {Spell 7} case(8) {Spell 8} case(9) {Spell 9} case(10) {Spell 10} case(11) {Spell 11} case(12) {Spell 12} case(13) {Spell 13} case(14) {Spell 14} case(15) {Spell 15} case(16) {Spell 16} } } return; } yield; } }