Esempio n. 1
0
        public Level2()
        {
            Console.WriteLine("Level2");
            Reset();
            timebarSpace = 10.768F;
            this.Add(new SpriteGameObject("spr_background"));

            thePlayer = new Player(3, 3);
            door      = new Door(14, 0);
            goal      = new MainGoal(26, 3);
            xaxis     = new Xaxis(8, "Map/spr_horizontal_art_blue");
            yaxis     = new Yaxis(20, "Map/spr_vertical_art_blue");

            Mouse.SetPosition(GameEnvironment.Screen.X / 2, GameEnvironment.Screen.Y / 2);

            floors = new GameObjectList();
            walls  = new GameObjectList();
            goals  = new GameObjectList();

            inputScreen = new InputScreen(GameEnvironment.Screen.X / 2 - 64 * 2, GameEnvironment.Screen.Y);
            inputanswer = new InputAnswer(GameEnvironment.Screen.X / 2 - 64 * 2, GameEnvironment.Screen.Y);
            timeGround  = new SpriteGameObject("Map/time_ground");

            guards       = new GameObjectList();
            lasers       = new GameObjectList();
            times        = new GameObjectList();
            score        = new Score(12, 20, (int)time);
            Axis_nums    = new Axis_numbers(20, 8);
            switchBoards = new GameObjectList();

            this.Add(floors);
            this.Add(switchBoards);
            this.Add(lasers);
            this.Add(walls);
            this.Add(door);
            this.Add(xaxis);
            this.Add(yaxis);
            this.Add(Axis_nums);
            this.Add(goal);
            this.Add(goals);
            this.Add(guards);
            this.Add(thePlayer);
            this.Add(inputScreen);
            this.Add(timeGround);
            this.Add(times);
            this.Add(score);
            this.Add(inputanswer);

            goals.Add(new ExtraGoal(11, 9));
            guards.Add(new Guard(new Vector2(3, 13), new Vector2(25, 13)));
            FloorSetup();
            WallSetup();
            TimeBarSetup();
            SoundSetup();
            lasers.Add(new Laser(new Vector2(11, 6), new Vector2(14, 10), Color.Red, xaxis.gridPos, yaxis.gridPos));
            lasers.Add(new Laser(new Vector2(23, 10), new Vector2(28, 7), Color.Blue, xaxis.gridPos, yaxis.gridPos));
            switchBoards.Add(new SwitchBoard(3, 7, Color.Blue));
            switchBoards.Add(new SwitchBoard(22, 3, Color.Red));
        }
Esempio n. 2
0
        // POST api/<controller>
        public IHttpActionResult Post([FromBody] MainGoal mainGoal)
        {
            mainGoalRepository.Add(mainGoal);

            return(Ok());
        }
Esempio n. 3
0
 private MainGoal(MainGoal goal)
 {
     nTerritoryGoal = goal.getNTerritoryGoal();
 }
Esempio n. 4
0
        public Level4()
        {
            Console.WriteLine("Level4");
            Reset();
            timebarSpace = 10.768F;
            this.Add(new SpriteGameObject("spr_background"));

            thePlayer = new Player(2, 2);
            door      = new Door(1, 0);
            xaxis     = new Xaxis(8, "Map/spr_horizontal_art_blue");
            yaxis     = new Yaxis(13, "Map/spr_vertical_art_blue");
            goal      = new MainGoal(3, 13);

            Mouse.SetPosition(GameEnvironment.Screen.X / 2, GameEnvironment.Screen.Y / 2);

            floors = new GameObjectList();
            walls  = new GameObjectList();
            goals  = new GameObjectList();

            inputScreen = new InputScreen(GameEnvironment.Screen.X / 2 - 64 * 2, GameEnvironment.Screen.Y);
            inputanswer = new InputAnswer(GameEnvironment.Screen.X / 2 - 64 * 2, GameEnvironment.Screen.Y);
            timeGround  = new SpriteGameObject("Map/time_ground");

            guards       = new GameObjectList();
            lasers       = new GameObjectList();
            times        = new GameObjectList();
            score        = new Score(12, 20, (int)time);
            Axis_nums    = new Axis_numbers(13, 8);
            switchBoards = new GameObjectList();

            this.Add(floors);
            this.Add(switchBoards);
            this.Add(lasers);
            this.Add(walls);
            this.Add(door);
            this.Add(xaxis);
            this.Add(yaxis);
            this.Add(Axis_nums);
            this.Add(goal);
            this.Add(goals);
            this.Add(guards);
            this.Add(thePlayer);
            this.Add(inputScreen);
            this.Add(timeGround);
            this.Add(times);
            this.Add(score);
            this.Add(inputanswer);

            goals.Add(new ExtraGoal(7, 2));
            goals.Add(new ExtraGoal(12, 2));
            goals.Add(new ExtraGoal(22, 2));
            goals.Add(new ExtraGoal(26, 2));
            goals.Add(new ExtraGoal(27, 2));
            goals.Add(new ExtraGoal(26, 3));
            goals.Add(new ExtraGoal(27, 3));
            goals.Add(new ExtraGoal(17, 8));
            goals.Add(new ExtraGoal(9, 13));
            goals.Add(new ExtraGoal(26, 13));
            FloorSetup();
            WallSetup();
            TimeBarSetup();
            SoundSetup();
            lasers.Add(new Laser(new Vector2(21, 9), new Vector2(28, 6), Color.Red, xaxis.gridPos, yaxis.gridPos));
            lasers.Add(new Laser(new Vector2(13, 10), new Vector2(19, 4), Color.Blue, xaxis.gridPos, yaxis.gridPos));
            lasers.Add(new Laser(new Vector2(14, 12), new Vector2(26, 15), Color.Yellow, xaxis.gridPos, yaxis.gridPos));
            lasers.Add(new Laser(new Vector2(7, 12), new Vector2(5, 15), Color.Purple, xaxis.gridPos, yaxis.gridPos));
            lasers.Add(new Laser(new Vector2(1, 9), new Vector2(5, 11), Color.Green, xaxis.gridPos, yaxis.gridPos));
            lasers.Add(new Laser(new Vector2(26, 5), new Vector2(28, 5), Color.DarkGray, xaxis.gridPos, yaxis.gridPos));
            lasers.Add(new Laser(new Vector2(1, 5), new Vector2(6, 10), Color.Aqua, xaxis.gridPos, yaxis.gridPos));
            switchBoards.Add(new SwitchBoard(15, 10, Color.Red));
            switchBoards.Add(new SwitchBoard(6, 10, Color.Blue));
            switchBoards.Add(new SwitchBoard(23, 10, Color.Yellow));
            switchBoards.Add(new SwitchBoard(20, 11, Color.Purple));
            switchBoards.Add(new SwitchBoard(10, 11, Color.Green));
            switchBoards.Add(new SwitchBoard(17, 11, Color.DarkGray));
            switchBoards.Add(new SwitchBoard(4, 4, Color.Aqua));
            guards.Add(new Guard(new Vector2(2, 13), new Vector2(25, 13)));
            guards.Add(new Guard(new Vector2(26, 13), new Vector2(27, 1)));
            guards.Add(new Guard(new Vector2(5, 8), new Vector2(11, 2)));
        }