Exemple #1
0
 public ErrorMessage(Mechanic m, Mechanic m2, Mechanic m3, Mechanic m4, Mechanic m5, Resources resoure)
 {
     this.Mech1 = m;
     this.Mech2 = m2;
     this.Mech3 = m3;
     this.Mech4 = m4;
     this.Mech5 = m5;
     this.Resoure = resoure;
 }
Exemple #2
0
 //constructor(s)
 public Event(double timespan, string eventName, DateTime currentTime, string startText, Mechanic chara)
 {
     this.Timespan = timespan;
     this.EventName = eventName;
     this.CurrentTime = currentTime;
     this.ETC = CurrentTime.AddSeconds(timespan);
     this.StartText = startText;
     this.Chara = chara;
 }
Exemple #3
0
 public SchedueldEvent(double timespan, string eventName, DateTime currentTime, string startText, Mechanic chara)
     : base(timespan, eventName, currentTime, startText, chara)
 {
     
 }
Exemple #4
0
        /// <summary>
        /// Allows the game to perform any initialization it needs to before starting to run.
        /// This is where it can query for any required services and load any non-graphic
        /// related content.  Calling base.Initialize will enumerate through any components
        /// and initialize them as well.
        /// </summary>
        protected override void Initialize()
        {
            // TODO: Add your initialization logic here
            clock = new DateTime();

            tab1Texture = Content.Load<Texture2D>("Tab Button Engineroom");
            tab2Texture = Content.Load<Texture2D>("Tab Button Infirmary");
            tab3Texture = Content.Load<Texture2D>("Tab Button Kitchen");

            b = new BackScroll(Content.Load<Texture2D>("space02"), Content.Load<Texture2D>("space03"), .03f);
            background = Content.Load<Texture2D>("background12");
            menu = Content.Load<Texture2D>("menu_layout");
            preStartScreen = new Button(Content.Load<Texture2D>("start00"), new Vector2(0,0), Color.White, ButtonName.Default);
            introScreen = Content.Load<Texture2D>("Intro");

            startButton = new Button(Content.Load<Texture2D>("Start Button"), new Vector2(GraphicsDevice.Viewport.Width - 300, 50), Color.White, ButtonName.Start);
            creditsButton = new Button(Content.Load<Texture2D>("Start Button"), new Vector2(GraphicsDevice.Viewport.Width - 300, 350), Color.White, ButtonName.Credits);
            quitButton = new Button(Content.Load<Texture2D>("Start Button"), new Vector2(GraphicsDevice.Viewport.Width - 300, 650), Color.White, ButtonName.Quit);

            elevator = new ForegroundObject(Content.Load<Texture2D>("elevator_002"), new Vector2(352, 264), 500, 500, 13, 4, 100);
            radar = new ForegroundObject(Content.Load<Texture2D>("radartech01"), new Vector2(1010, 420), 350, 100, 4, 2, 100);
            screen = new ForegroundObject(Content.Load<Texture2D>("screen01"), new Vector2(990, 140), 350, 300, 2, 2, 100);
            loseScreen = new ForegroundObject(Content.Load<Texture2D>("end_screen02"), new Vector2(0, 0), 1600, 900, 2, 2, 100);

            Characters = new List<Character>();

            this.IsMouseVisible = true;

            spaceBackground = Content.Load<Texture2D>("Space BG");
            
            base.Initialize();

            RoomTabs = new List<RoomTab>();
            RoomTextures = new List<Texture2D>();

            resource = new Resources(Content.Load<Texture2D>("resource_button"), new Vector2(2, 18), testFont, spriteBatch, 200, 300, 100, 3000, 100);

            buttonList = new List<Button>();

            victoryTexture = Content.Load<Texture2D>("victory_00");
            victoryPos = new Vector2(-1000, 0);
            
            //Setting graphics settings
            graphics.PreferredBackBufferWidth = 1600;
            graphics.PreferredBackBufferHeight = 900;
            graphics.IsFullScreen = true;
            graphics.ApplyChanges();
            rand = new Random();
            //Initializing characters
            spencer = new Mechanic(Content.Load<Texture2D>("spencer_idle_04"), new Vector2(1100, 400), RoomE.Bridge, resource, "Spencer Bara", 300, 300, 3, 2, new Button(Content.Load<Texture2D>("button"), new Vector2(400, 665), Color.White, ButtonName.Eat),
                new Button(Content.Load<Texture2D>("button"), new Vector2(850, 665), Color.White, ButtonName.Resolve), new Button(Content.Load<Texture2D>("button"), new Vector2(400, 790), Color.White, ButtonName.Heal), new Button(Content.Load<Texture2D>("button")
                    , new Vector2(850, 790), Color.White, ButtonName.Upgrade), Content.Load<Texture2D>("spencer_walk_left_00"), 8, 3, Content.Load<Texture2D>("spencer_walk_right_01"), 8, 3, Content.Load<Texture2D>("spencer_walk_up_04"), 8, 3, Content.Load<Texture2D>("spencer_walk_down_05"), 8, 3,
                    5, 5, 5, 5, 5, 100, "", Content.Load<Texture2D>("Portrait Spencer"), Content.Load<Texture2D>("Spencer Dead"), Content.Load<Texture2D>("Spencer dead still"));

            spencer.ID = 4;

            lavender = new Mechanic(Content.Load<Texture2D>("Lavender_Idle"), new Vector2(500, 400), RoomE.Bridge, resource, "Lavender Flowers", 174, 300, 10, 5, new Button(Content.Load<Texture2D>("button"), new Vector2(400, 665), Color.White, ButtonName.Eat),
                new Button(Content.Load<Texture2D>("button"), new Vector2(850, 665), Color.White, ButtonName.Resolve), new Button(Content.Load<Texture2D>("button"), new Vector2(400, 790), Color.White, ButtonName.Heal), new Button(Content.Load<Texture2D>("button")
                    , new Vector2(850, 790), Color.White, ButtonName.Upgrade), Content.Load<Texture2D>("lavender walk left"), 8, 5, Content.Load<Texture2D>("lavender walk right"), 8, 5, Content.Load<Texture2D>("Lavender Walk Back"), 8, 5, Content.Load<Texture2D>("Lavender Walk Front"), 8, 5,
                    5, 5, 5, 5, 5, 100, "", Content.Load<Texture2D>("Portrait Lavender"), Content.Load<Texture2D>("Lavender Dead"), Content.Load<Texture2D>("Lavender dead still"));
            lavender.ID = 5;

            dora = new Mechanic(Content.Load<Texture2D>("Dora Hairflip"), new Vector2(700, 400), RoomE.Bridge, resource, "Dora \"the Explorah\" Dandy", 174, 300, 13, 5, new Button(Content.Load<Texture2D>("button"), new Vector2(400, 665), Color.White, ButtonName.Eat),
                new Button(Content.Load<Texture2D>("button"), new Vector2(850, 665), Color.White, ButtonName.Resolve), new Button(Content.Load<Texture2D>("button"), new Vector2(400, 790), Color.White, ButtonName.Heal), new Button(Content.Load<Texture2D>("button")
                    , new Vector2(850, 790), Color.White, ButtonName.Upgrade), Content.Load<Texture2D>("Dora Walk Left"), 8, 5, Content.Load<Texture2D>("Dora Walk Right"), 8, 5, Content.Load<Texture2D>("Dora Walk Back"), 8, 5, Content.Load<Texture2D>("Dora Walk Front"), 8, 5,
                    5, 5, 5, 5, 5, 100, "", Content.Load<Texture2D>("Portrait Dora"), Content.Load<Texture2D>("Dora Dead"), Content.Load<Texture2D>("Dora dead still"));

            dora.ID = 3;

            mechanic = new Mechanic(Content.Load<Texture2D>("Kitty Breath Blink"), new Vector2(1000, 450), RoomE.Bridge, resource, "Kitty Kat", 174, 300, 9, 5, new Button(Content.Load<Texture2D>("button"), new Vector2(400, 665), Color.White, ButtonName.Eat),
                new Button(Content.Load<Texture2D>("button"), new Vector2(850, 665), Color.White, ButtonName.Resolve), new Button(Content.Load<Texture2D>("button"), new Vector2(400, 790), Color.White, ButtonName.Heal), new Button(Content.Load<Texture2D>("button")
                    , new Vector2(850, 790), Color.White, ButtonName.Upgrade), Content.Load<Texture2D>("Kitty Walk Left"), 8, 5, Content.Load<Texture2D>("Kitty Walk Right"), 8, 5, Content.Load<Texture2D>("Kitty Walk Back"), 9, 5, Content.Load<Texture2D>("Kitty Walk Front"),
                    9, 5, 5, 5, 5, 8, 5, 100, "Olaf", Content.Load<Texture2D>("Portrait Kitty"), Content.Load<Texture2D>("Kitty Dead"), Content.Load<Texture2D>("Kitty dead still"));

            mechanic.ID = 1;

            mechanic2 = new Mechanic(Content.Load<Texture2D>("idle_pose02"), new Vector2(300, 450), RoomE.Bridge, resource, "Blondie Bubs", 300, 300, 8, 3, new Button(Content.Load<Texture2D>("button"), new Vector2(400, 665), Color.White, ButtonName.Eat),
                new Button(Content.Load<Texture2D>("button"), new Vector2(850, 665), Color.White, ButtonName.Resolve), new Button(Content.Load<Texture2D>("button"), new Vector2(400, 790), Color.White, ButtonName.Heal), new Button(Content.Load<Texture2D>("button")
                    , new Vector2(850, 790), Color.White, ButtonName.Upgrade), Content.Load<Texture2D>("walk_right_03"), 8, 3, Content.Load<Texture2D>("walk_right_03"), 8, 3, Content.Load<Texture2D>("walk_up_02"), 8, 3, Content.Load<Texture2D>("walk_up_02"), 8, 3,
                    5, 5, 5, 5, 5, 100, "Olaf", Content.Load<Texture2D>("Portrait Blondie"), Content.Load<Texture2D>("Blondie Dead"), Content.Load<Texture2D>("Blondie dead still"));

            mechanic2.ID = 2;

            ListOfChars.statListChar.Add(dora);
            ListOfChars.statListChar.Add(mechanic);
            ListOfChars.statListChar.Add(mechanic2);
            ListOfChars.statListChar.Add(spencer);
            ListOfChars.statListChar.Add(lavender);

            p = new ErrorMessage(mechanic, mechanic2, dora, spencer, lavender, resource);

            //Initializing events
            RoomCamera2 = Content.Load<Texture2D>("Engineroom05");
            RoomCamera3 = Content.Load<Texture2D>("infirmary003");
            RoomCamera4 = Content.Load<Texture2D>("kitchen_02");
            RoomTextures.Add(RoomCamera2);
            RoomTextures.Add(RoomCamera3);
            RoomTextures.Add(RoomCamera4);
            roomTab2 = new RoomTab(tab1Texture, new Vector2(1500, 150), "engineRoom", RoomE.EngineRoom, RoomCamera2);
            roomTab3 = new RoomTab(tab2Texture, new Vector2(1500, 250), "Infirmary", RoomE.Infirmary, RoomCamera3);
            roomTab4 = new RoomTab(tab3Texture , new Vector2(1500, 350), "Kitchen", RoomE.Kitchen, RoomCamera4);
            RoomTabs.Add(roomTab2);
            RoomTabs.Add(roomTab3);
            RoomTabs.Add(roomTab4);
           
            //Initializing variables
            maxEvents = 5;
        }