Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
- %%%%%%%%%%%%%%%%%%% HALO 4 : DISCOVERY VIDEO GAME %%%%%%%%%%%%%%%%%%%%
- %%%%%%%%%%%%%%%% PROGRAM CREATED BY : PATRICK %%%%%%%%%%%%%%%%%%
- %%%%%%%%%%%%%%%%%%% PROGRAM CREATED ON : %%%%%%%%%%%%%%%%%%%%%%%%%%%%%
- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
- %Button GUI
- import GUI
- %Declaring Variables
- var winID : int
- var halo_cover : int
- var cio_armor : int
- var fotus_armor : int
- var rogue_armor : int
- var orbital_armor : int
- var mark6_armor : int
- var halo_splash_pic : int
- var cio_armor_display : int
- var fotus_armor_display : int
- var rogue_armor_display : int
- var orbital_armor_display : int
- var mark6_armor_display : int
- var font1 : int
- var font2 : int
- var font3 : int
- var splash_response : string (1)
- var name : string
- var intro_pic : int
- var intro_pic_draw : int
- var welcome_pic : int
- var welcome_pic_draw : int
- var forward_unto_dawn : int
- var forward_unto_dawn_pic : int
- var mission1_pic1 : int
- var mission1_pic1_pic : int
- var cryotube : int
- var cryotube_pic : int
- var mission1_deathgetch : string (1)
- %Putting pictures into memory
- halo_cover := Pic.FileNew ("Qvtn8.jpg")
- cio_armor := Pic.FileNew ("cio armor.jpg")
- fotus_armor := Pic.FileNew ("fotus armor.jpg")
- rogue_armor := Pic.FileNew ("rogue armor.jpg")
- orbital_armor := Pic.FileNew ("orbital armor.jpg")
- mark6_armor := Pic.FileNew ("mark 6 armor.jpg")
- intro_pic := Pic.FileNew ("halo4_unsc_01_blue.jpg")
- welcome_pic := Pic.FileNew ("halo4multiplayer.jpg")
- forward_unto_dawn := Pic.FileNew ("halo_4___unsc_forward_unto_dawn_by_goyo_noble_141-d5fjs69.jpg")
- cryotube := Pic.FileNew ("halo4crytube.jpg")
- mission1_pic1 := Pic.FileNew ("halomission1.jpg")
- %Create Run Window
- winID := Window.Open ("graphics:max;max")
- %Set Title Bar
- View.Set ("Title:Halo 4: Discovery")
- %Color of Background
- colorback (black)
- color (white)
- cls
- %Procedure Forwards
- forward procedure splash_screen
- forward procedure intro_to_game
- forward procedure welcome_screen
- forward procedure cio_button
- forward procedure fotus_button
- forward procedure rogue_button
- forward procedure orbital_button
- forward procedure mark6_button
- forward procedure armor_selection
- forward procedure mission_selection
- forward procedure mission1_1
- forward procedure mission1_2
- forward procedure mission1_death
- forward procedure mission1_button_code
- forward procedure mission2_button_code
- forward procedure mission3_button_code
- forward procedure mission4_button_code
- forward procedure mission1_answer1_button
- forward procedure mission1_answer2_button
- forward procedure mission1_answer3_button
- forward procedure mission1_answer4_button
- forward procedure mission1_bonus
- forward procedure mission1_3
- forward procedure mission2_1
- forward procedure mission3_1
- forward procedure mission4_1
- %Procedures in Program
- body procedure splash_screen
- halo_splash_pic := Pic.Scale (halo_cover, maxx, maxy)
- Pic.Draw (halo_splash_pic, 0, 0, picCopy)
- font1 := Font.New ("Tele-Marines:20")
- Font.Draw ("Press Enter to Start", 425, 100, font1, white)
- getch (splash_response)
- cls
- end splash_screen
- body procedure intro_to_game
- intro_pic_draw := Pic.Scale (intro_pic, maxx, maxy)
- Pic.Draw (intro_pic_draw, 0, 0, picCopy)
- drawfillbox (0, 0, 1500, 140, black)
- font2 := Font.New ("SimHei:20")
- Font.Draw ("Welcome to Halo 4. You are a genetically modified supersoldier", 80, 100, font2, white)
- Font.Draw (" called a SPARTAN working for the UNSC. (United Nations Space Command)", 85, 75, font2, white)
- delay (3000)
- Font.Draw ("Please Enter your name here: ", 200, 45, font2, white)
- loop
- locate (40, 76)
- get name : *
- exit when name not= ""
- end loop
- delay (100)
- cls
- end intro_to_game
- body procedure welcome_screen
- welcome_pic_draw := Pic.Scale (welcome_pic, maxx, maxy)
- Pic.Draw (welcome_pic_draw, 0, 0, picCopy)
- Font.Draw ("Welcome to the SPARTAN", 20, 420, font2, black)
- Font.Draw ("program " + name + ".", 20, 390, font2, black)
- delay (3000)
- cls
- end welcome_screen
- body procedure armor_selection
- Font.Draw ("Please select your armor you will be using for your SPARTAN career.", 100, 600, font2, white)
- Font.Draw ("(Only Click your Selection Once)", 200, 570, font2, white)
- cio_armor_display := Pic.Scale (cio_armor, 290, 470)
- Pic.Draw (cio_armor_display, 0, 0, picCopy)
- fotus_armor_display := Pic.Scale (fotus_armor, 290, 470)
- Pic.Draw (fotus_armor_display, 260, 0, picCopy)
- rogue_armor_display := Pic.Scale (rogue_armor, 290, 470)
- Pic.Draw (rogue_armor_display, 540, 0, picCopy)
- orbital_armor_display := Pic.Scale (orbital_armor, 290, 470)
- Pic.Draw (orbital_armor_display, 790, 0, picCopy)
- mark6_armor_display := Pic.Scale (mark6_armor, 290, 470)
- Pic.Draw (mark6_armor_display, 1070, 0, picCopy)
- cio_button
- fotus_button
- rogue_button
- orbital_button
- mark6_button
- end armor_selection
- body procedure cio_button
- var cio_armor_button : int := GUI.CreateButton (100, 490, 0, "C.I.O. Armor", mission_selection)
- GUI.SetColor (cio_armor_button, 41)
- end cio_button
- body procedure fotus_button
- var fotus_armor_button : int := GUI.CreateButton (360, 490, 0, "Fotus Armor", mission_selection)
- GUI.SetColor (fotus_armor_button, 24)
- end fotus_button
- body procedure rogue_button
- var rogue_armor_button : int := GUI.CreateButton (635, 490, 0, "Rogue Armor", mission_selection)
- GUI.SetColor (rogue_armor_button, 55)
- end rogue_button
- body procedure orbital_button
- var orbital_armor_button : int := GUI.CreateButton (880, 490, 0, "Orbital Armor", mission_selection)
- GUI.SetColor (orbital_armor_button, 40)
- end orbital_button
- body procedure mark6_button
- var mark6_armor_button : int := GUI.CreateButton (1150, 490, 0, "Mark VI Armor", mission_selection)
- GUI.SetColor (mark6_armor_button, 48)
- end mark6_button
- RIGHT HERE THIS IS THE PROBLEM --V --^
- body procedure mission_selection
- cls
- GUI.Dispose (cio_armor_button)
- GUI.Dispose (fotus_armor_button)
- GUI.Dispose (rogue_armor_button)
- GUI.Dispose (orbital_armor_button)
- GUI.Dispose (mark6_armor_button)
- mission1_button_code
- mission2_button_code
- mission3_button_code
- mission4_button_code
- end mission_selection
- body procedure mission1_button_code
- var mission1_button : int := GUI.CreateButton (100, 490, 0, "Click Here for Mission 1", mission1_1)
- GUI.SetColor (mission1_button, 41)
- end mission1_button_code
- body procedure mission2_button_code
- var mission2_button : int := GUI.CreateButton (360, 490, 0, "Click Here for Mission 2", mission2_1)
- GUI.SetColor (mission2_button, 24)
- end mission2_button_code
- body procedure mission3_button_code
- var mission3_button : int := GUI.CreateButton (635, 490, 0, "Click Here for Mission 3", mission3_1)
- GUI.SetColor (mission3_button, 55)
- end mission3_button_code
- body procedure mission4_button_code
- var mission4_button : int := GUI.CreateButton (880, 490, 0, "Click Here for Mission 4", mission4_1)
- GUI.SetColor (mission4_button, 40)
- end mission4_button_code
- body procedure mission2_1
- put "TEST"
- end mission2_1
- body procedure mission3_1
- put "TEST"
- end mission3_1
- body procedure mission4_1
- put "TEST"
- end mission4_1
- body procedure mission1_death
- put "YOU DIED!"
- getch (mission1_deathgetch)
- end mission1_death
- body procedure mission1_1
- cls
- forward_unto_dawn_pic := Pic.Scale (forward_unto_dawn, 1350, 700)
- Pic.DrawSpecial (forward_unto_dawn_pic, 0, 0, picCopy, picFadeIn, 3000)
- font3 := Font.New ("SimHei:14")
- Font.Draw ("System: RE-ACTIVATING " + name + ".", 70, 65, font3, white)
- delay (2000)
- cls
- Pic.DrawSpecial (cryotube, 360, 0, picCopy, picFadeIn, 2000)
- delay (500)
- drawfillbox (0, 0, 1500, 140, black)
- Font.Draw ("*HISSING SOUND*", 600, 65, font3, white)
- delay (2000)
- cls
- mission1_pic1_pic := Pic.Scale (mission1_pic1, maxx, maxy)
- Pic.Draw (mission1_pic1_pic, 0, 0, picCopy)
- drawfillbox (0, 0, 1500, 140, black)
- Font.Draw ("Joanna: Glad you woke up, we have several intruder alerts appearing on multiple decks!", 0, 100, font3, white)
- delay (1000)
- Font.Draw (name + ": Let's get to work then.", 0, 80, font3, white)
- delay (7000)
- cls
- drawfillbox (0, 0, 1500, 140, black)
- Font.Draw ("You walk for a few minutes until you come across an intersection with two paths. Which path will you take?", 0, 60, font3, yellow)
- mission1_answer1_button
- mission1_answer2_button
- end mission1_1
- body procedure mission1_answer1_button
- var mission1_answer1_button : int := GUI.CreateButton (880, 490, 0, "Click Here to go Right.", mission1_death)
- GUI.SetColor (mission1_answer1_button, 40)
- end mission1_answer1_button
- body procedure mission1_answer2_button
- var mission1_answer2_button : int := GUI.CreateButton (880, 450, 0, "Click Here to go Left.", mission1_2)
- GUI.SetColor (mission1_answer2_button, 40)
- end mission1_answer2_button
- body procedure mission1_2
- cls
- Font.Draw ("You decide to take a right. Good choice, because the ceiling of the section of the ship led left collapsed.", 0, 60, font3, yellow)
- Font.Draw ("Walking forward for a minute you realize how badly the ship has deteriorated.", 0, 60, font3, yellow)
- Font.Draw ("There's a terminal up ahead. You go to it and Joanna appears on the screen.", 0, 60, font3, yellow)
- Font.Draw ("Joanna: It seems we've been floating in space for 7 years, 3 months and 13 days.", 0, 60, font3, white)
- Font.Draw (name + ": Someone should have found us by now...", 0, 60, font3, white)
- Font.Draw ("Joanna: Let's go to the bridge, maybe we can find out where we are.", 0, 60, font3, white)
- Font.Draw ("Joanna disappears off the screen and you continue to move along through the ship.", 0, 60, font3, yellow)
- Font.Draw ("There's an elevator shaft to your left and another room to your right.", 0, 60, font3, yellow)
- Font.Draw ("Which way will you go?", 0, 60, font3, yellow)
- mission1_answer3_button
- mission1_answer4_button
- end mission1_2
- body procedure mission1_answer3_button
- var mission1_answer3_button : int := GUI.CreateButton (880, 490, 0, "Click Here to go up the elevator.", mission1_3)
- GUI.SetColor (mission1_answer3_button, 40)
- end mission1_answer3_button
- body procedure mission1_answer4_button
- var mission1_bonusanswer_button : int := GUI.CreateButton (880, 450, 0, "Click Here to go into the room to your right.", mission1_bonus)
- GUI.SetColor (mission1_bonusanswer_button, 40)
- end mission1_answer4_button
- body procedure mission1_bonus
- put "WOOO, YOU FOUND A SECRET!"
- end mission1_bonus
- body procedure mission1_3
- put "MISSION1_3"
- end mission1_3
- %DEPLOYING OF PROCEDURES
- splash_screen
- intro_to_game
- welcome_screen
- armor_selection
- loop
- exit when GUI.ProcessEvent
- end loop
Advertisement
Add Comment
Please, Sign In to add comment