Exemplo n.º 1
0
        public Map(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                @"Images\ALL\Game\Map\MapScreen_Hole_Idle.jpg",
                94, 61, 33, 43,
                0, 0, 800, 600)
        {
            _gopherHole = CreateTemplateButton(
                @"Images\ALL\Game\Map\MapScreen_Gopher_Idle.jpg",
                105, 54, 11, 45);

            _currentLocation = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\Map\MapScreen_Hole_Idle.jpg")
                .Copy(new Rectangle(94, 61, 33, 43));

            _openHole = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\Map\MapScreen_Hole_Small.jpg")
                .Copy(new Rectangle(96, 85, 27, 13));

            _zones = new List<Rectangle>
            {
                new Rectangle(108, 45, 147, 261),
                new Rectangle(50, 294, 235, 284),
                new Rectangle(300, 238, 204, 333),
                new Rectangle(298, 0, 240, 275),
                new Rectangle(540, 0, 249, 306),
                new Rectangle(513, 290, 287, 310)
            };
        }
Exemplo n.º 2
0
 public BonusGameWaiting(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\ALL\Game\bonus_game\BG_Background.jpg",
         98, 386, 96, 23,
         90, 382, 111, 32)
 {
 }
Exemplo n.º 3
0
        protected TextScreen(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger, int x, int y, int width, int height, string text)
            : base(autoIt, assetCatalog, logger)
        {
            AdditionalCharacters = String.Empty;
            RequiresZoom = false;

            _rectangle = new Rectangle(x, y, width, height);
            _text = text;
        }
Exemplo n.º 4
0
 public SpeechBubble(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\ALL\Game\Common\Dialog_SpeechBubble_GS_Sm.jpg",
         18, 13, 242, 20,
         377, 79, 423, 303)
 {
 }
Exemplo n.º 5
0
 public BonusGameComplete(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         252, 198, 288, 37,
         "BONUS GAME")
 {
     _ok = CreateCoordinateButton(328, 360, 150, 38);
 }
Exemplo n.º 6
0
 public GameSummary(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\ALL\Game\GameSummary\Dialog_GS_BG.jpg",
         506, 97, 79, 32,
         527, 90, 89, 43)
 {
 }
Exemplo n.º 7
0
 public Intro(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\ALL\Dialog\Dialog_Loc\Dialog_Loc_BG.jpg",
         274, 469, 198, 106,
         0, 400, 800, 200)
 {
     _accept = CreateTemplateButton(@"Images\ALL\Dialog\Dialog_Arrow_Right_Idle.jpg", 10, 14, 74, 35);
 }
Exemplo n.º 8
0
 public FinaleOne(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\EN_US\Dialog\Dialog_Finale\Story_01.jpg",
         52, 149, 182, 29,
         27, 127, 227, 73)
 {
     _accept = CreateTemplateButton(@"Images\ALL\Dialog\Dialog_Arrow_Right_Idle.jpg", 10, 14, 74, 35);
 }
Exemplo n.º 9
0
 public MainMenu(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\EN_US\Menu\MainMenu_Button_PogoLogo.jpg",
         0, 0, 72, 40,
         0, 418, 231, 97)
 {
     _play = CreateCoordinateButton(20, 323, 128, 38);
 }
Exemplo n.º 10
0
 public FinaleTwo(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\EN_US\Dialog\Dialog_Finale\Story_02.jpg",
         496, 20, 261, 22,
         465, 8, 331, 92)
 {
     _accept = CreateTemplateButton(@"Images\ALL\Dialog\Dialog_Arrow_Right_Idle.jpg", 10, 14, 74, 35);
 }
Exemplo n.º 11
0
 public PuzzleGameComplete(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\ALL\Game\puzzle_game\PuzzleGame_Background.jpg",
         11, 556, 277, 35,
         0, 540, 370, 60)
 {
     _ok = CreateCoordinateButton(600, 301, 98, 23);
 }
Exemplo n.º 12
0
 public FinaleThree(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\EN_US\Dialog\Dialog_Finale\Story_03.jpg",
         406, 290, 89, 130,
         354, 263, 213, 228)
 {
     _ok = CreateCoordinateButton(636, 545, 150, 37);
 }
Exemplo n.º 13
0
 public Paused(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\ALL\Dialog\Dialog_565x540.jpg",
         15, 20, 580, 63,
         86, 3, 623, 122)
 {
     _ok = CreateCoordinateButton(333, 471, 124, 34);
 }
Exemplo n.º 14
0
 public IntroComplete(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
     : base(autoIt,
         assetCatalog,
         logger,
         @"Images\ALL\Dialog\Dialog_Loc\Dialog_Loc_BG.jpg",
         641, 464, 150, 127,
         590, 420, 210, 180)
 {
     _accept = CreateCoordinateButton(326, 519, 152, 37);
 }
Exemplo n.º 15
0
        public PaintBrush(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                493, 160, 211, 22,
                "WANT TO SEE IF WE CAN FIX THE")
        {
            RequiresZoom = true;

            _ok = CreateCoordinateButton(547, 247, 40, 23);
        }
Exemplo n.º 16
0
        public NewGearFull(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                347, 161, 81, 23,
                "NOW FULL!")
        {
            AdditionalCharacters = "!";
            RequiresZoom = true;

            _ok = CreateCoordinateButton(418, 250, 99, 24);
        }
Exemplo n.º 17
0
        public NewGear(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                489, 141, 168, 25,
                "YOU FOUND A NEW GEAR!")
        {
            AdditionalCharacters = "!";
            RequiresZoom = true;

            _yes = CreateCoordinateButton(488, 224, 97, 21);
        }
Exemplo n.º 18
0
        public BlowTorch(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                475, 139, 189, 22,
                "YOU FOUND A BLOW TORCH!")
        {
            AdditionalCharacters = "!";
            RequiresZoom = true;

            _ok = CreateCoordinateButton(488, 225, 96, 23);
        }
Exemplo n.º 19
0
        public BonusAcorns(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                493, 160, 211, 22,
                "LET'S TAKE THEM TO THE BONUS")
        {
            AdditionalCharacters = "'";
            RequiresZoom = true;

            _ok = CreateCoordinateButton(548, 223, 96, 22);
        }
Exemplo n.º 20
0
        protected TemplateScreen(
            IAutoIt autoIt,
            IAssetCatalog assetCatalog,
            ILogger logger,
            string fileName,
            int x, int y, int width, int height,
            int activeX, int activeY, int activeWidth, int activeHeight)
            : base(autoIt, assetCatalog, logger)
        {
            _autoIt = autoIt;
            _fileName = fileName;
            _templateRectangle = new Rectangle(x, y, width, height);
            _activeRectangle = new Rectangle(activeX, activeY, activeWidth, activeHeight);

            _template = AssetCatalog.GetCompositeImage(_fileName).Copy(_templateRectangle);
        }
Exemplo n.º 21
0
 public WordWhomper(IKernel kernel, ILogger logger, IAutoIt autoIt)
     : base(kernel, logger, autoIt)
 {
     RegisterScreen<MainMenu, AcceptDialogWithTransitionStrategy>();
     RegisterScreen<Intro, AcceptDialogWithoutWaitingStrategy>();
     RegisterScreen<IntroComplete, AcceptDialogWithoutWaitingStrategy>();
     RegisterScreen<Map, MapStrategy>();
     RegisterScreen<Paused, AcceptDialogWithoutWaitingStrategy>();
     RegisterScreen<SpeechBubble, SpeechBubbleStrategy>();
     RegisterScreen<InGame, GamePakDictionaryStrategy>();
     RegisterScreen<GameSummary, GameSummaryStrategy>();
     RegisterScreen<BonusGameWaiting, BonusGameWaitingStrategy>();
     RegisterScreen<InBonusGame, BonusGameStrategy>();
     RegisterScreen<InPuzzleGame, PuzzleGameStrategy>();
     RegisterScreen<BonusGameComplete, AcceptDialogWithTransitionStrategy>();
     RegisterScreen<FinaleOne, AcceptDialogWithoutWaitingStrategy>();
     RegisterScreen<FinaleTwo, AcceptDialogWithoutWaitingStrategy>();
     RegisterScreen<FinaleThree, ShutdownStrategy>();
 }
Exemplo n.º 22
0
        public InGame(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                @"Images\ALL\Game\gophers\burrow\Gopher_BUR_IDLE.jpg",
                15, 40, 12, 24,
                133, 517, 45, 79)
        {
            _gamePieces.Add(new TemplateCoordinate(182, 399, 53, 35));
            _gamePieces.Add(new TemplateCoordinate(259, 394, 53, 35));
            _gamePieces.Add(new TemplateCoordinate(336, 399, 53, 35));
            _gamePieces.Add(new TemplateCoordinate(413, 394, 53, 35));
            _gamePieces.Add(new TemplateCoordinate(490, 399, 53, 35));
            _gamePieces.Add(new TemplateCoordinate(567, 394, 53, 35));

            _menuButton = CreateCoordinateButton(12, 537, 74, 18);
            _mapButton = CreateCoordinateButton(12, 472, 73, 14);
            _exitConfirmButton = CreateCoordinateButton(208, 343, 149, 34);

            var backgroundRectangle = new Rectangle(351, 274, 69, 26);
            _backgrounds = new List<Image<Bgra, byte>>
            {
                assetCatalog.GetCompositeImage(@"Images\ALL\Game\backgrounds\BG_01.jpg")
                    .Copy(backgroundRectangle),
                assetCatalog.GetCompositeImage(@"Images\ALL\Game\backgrounds\BG_02.jpg")
                    .Copy(backgroundRectangle),
                assetCatalog.GetCompositeImage(@"Images\ALL\Game\backgrounds\BG_03.jpg")
                    .Copy(backgroundRectangle),
                assetCatalog.GetCompositeImage(@"Images\ALL\Game\backgrounds\BG_04.jpg")
                    .Copy(backgroundRectangle),
                assetCatalog.GetCompositeImage(@"Images\ALL\Game\backgrounds\BG_05.jpg")
                    .Copy(backgroundRectangle),
                assetCatalog.GetCompositeImage(@"Images\ALL\Game\backgrounds\BG_06.jpg")
                    .Copy(backgroundRectangle),
            };

            _backgroundSearchArea = new Rectangle(338, 264, 104, 68);
        }
Exemplo n.º 23
0
 public TemplateButton(IAutoIt autoIt, ILogger logger, IAssetCatalog assetCatalog, string fileName, Rectangle rectangle)
 {
     _autoIt = autoIt;
     _logger = logger;
     _template = assetCatalog.GetCompositeImage(fileName).Copy(rectangle);
 }
Exemplo n.º 24
0
        public InPuzzleGame(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger, FontLoader fontLoader)
            : base(autoIt,
                assetCatalog,
                logger,
                @"Images\ALL\Game\puzzle_game\PuzzleGame_Background.jpg",
                11, 556, 277, 35,
                0, 550, 320, 50)
        {
            _submit = CreateCoordinateButton(269, 303, 92, 41);
            _back = CreateCoordinateButton(73, 40, 76, 22);

            // Gear spots
            _inactiveGearSpot = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_NonInteractive.jpg")
                .Copy(new Rectangle(25, 26, 38, 38));

            _largeCopperGearSpot = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\GearSpot_Large_Copper.jpg")
                .Copy(new Rectangle(30, 32, 29, 29));

            _smallCopperGearSpot = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\GearSpot_Small_Copper.jpg")
                .Copy(new Rectangle(34, 37, 20, 19));

            _largeSilverGearSpot = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\GearSpot_Large_Silver.jpg")
                .Copy(new Rectangle(33, 34, 24, 25));

            _smallSilverGearSpot = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\GearSpot_Small_Silver.jpg")
                .Copy(new Rectangle(35, 37, 18, 18));

            _largeGoldGearSpot = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\GearSpot_Large_Gold.jpg")
                .Copy(new Rectangle(34, 37, 23, 22));

            _smallGoldGearSpot = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\GearSpot_Small_Gold.jpg")
                .Copy(new Rectangle(36, 38, 17, 17));

            // Gears
            _largeWildcardGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Large_Wildcard.jpg")
                .Copy(new Rectangle(30, 33, 28, 25));

            _smallWildcardGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Small_Wildcard.jpg")
                .Copy(new Rectangle(28, 29, 32, 32));

            _largeCopperGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Large_Copper.jpg")
                .Copy(new Rectangle(25, 65, 38, 3));

            _smallCopperGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Small_Copper.jpg")
                .Copy(new Rectangle(27, 32, 5, 32));

            _largeSilverGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Large_Silver.jpg")
                .Copy(new Rectangle(25, 65, 38, 3));

            _smallSilverGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Small_Silver.jpg")
                .Copy(new Rectangle(27, 32, 5, 32));

            _largeGoldGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Large_Gold.jpg")
                .Copy(new Rectangle(25, 65, 38, 3));

            _smallGoldGear = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\Gear_Small_Gold.jpg")
                .Copy(new Rectangle(27, 32, 5, 32));

            // Tools
            _torch = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\PowerUp_Torch_Idle.jpg")
                .Copy(new Rectangle(14, 59, 24, 31));

            _copperPaint = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\PowerUp_Brush_Copper_Idle.jpg")
                .Copy(new Rectangle(13, 51, 19, 32));

            _silverPaint = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\PowerUp_Brush_Silver_Idle.jpg")
                .Copy(new Rectangle(9, 59, 22, 32));

            _goldPaint = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\puzzle_game\PowerUp_Brush_Gold_Idle.jpg")
                .Copy(new Rectangle(6, 48, 28, 25));

            _letterSearchAreaTesseractArea = new Dictionary<Rectangle, Rectangle>
            {
                // top row
                { new Rectangle(29, 370, 76, 82), new Rectangle(55, 398, 25, 27) },
                { new Rectangle(119, 368, 79, 86), new Rectangle(146, 398, 25, 27) },
                { new Rectangle(214, 373, 73, 78), new Rectangle(238, 398, 25, 27) },
                { new Rectangle(301, 373, 75, 77), new Rectangle(326, 398, 25, 27) },
                { new Rectangle(392, 372, 76, 79), new Rectangle(417, 398, 25, 27) },
                { new Rectangle(483, 371, 76, 83), new Rectangle(509, 398, 25, 27) },
                { new Rectangle(577, 375, 73, 76), new Rectangle(600, 398, 25, 27) },
                { new Rectangle(670, 375, 72, 74), new Rectangle(693, 398, 25, 27) },

                // bottom row
                { new Rectangle(33, 465, 72, 73), new Rectangle(56, 486, 25, 27) },
                { new Rectangle(123, 461, 71, 78), new Rectangle(146, 486, 25, 27) },
                { new Rectangle(215, 463, 71, 74), new Rectangle(237, 486, 25, 27) },
                { new Rectangle(300, 463, 74, 73), new Rectangle(325, 486, 25, 27) },
                { new Rectangle(394, 465, 70, 72), new Rectangle(416, 486, 25, 27) },
                { new Rectangle(485, 461, 73, 77), new Rectangle(509, 486, 25, 27) },
                { new Rectangle(576, 462, 73, 75), new Rectangle(600, 486, 25, 27) },
            };

            _gearOne = CreateCoordinateButton(234, 125, 9, 9);
            _gearTwo = CreateCoordinateButton(292, 155, 8, 7);
            _gearThree = CreateCoordinateButton(354, 147, 11, 8);
            _gearFour = CreateCoordinateButton(412, 173, 9, 10);
            _gearFive = CreateCoordinateButton(476, 165, 7, 6);

            _gearSpotOne = new Rectangle(203, 92, 72, 74);
            _gearSpotTwo = new Rectangle(260, 123, 72, 72);
            _gearSpotThree = new Rectangle(322, 114, 73, 72);
            _gearSpotFour = new Rectangle(380, 139, 70, 73);
            _gearSpotFive = new Rectangle(443, 130, 72, 75);

            _torchSpot = new Rectangle(179, 259, 76, 117);
            _paintSpot = new Rectangle(0, 241, 208, 155);

            _trash = new Rectangle(676, 474, 51, 59);
            _trashConfirm = CreateCoordinateButton(524, 266, 98, 23);

            _gearFont = fontLoader.LoadFont(@"PG_GearLtr_Large23");
        }
Exemplo n.º 25
0
 public CoordinateButton(IAutoIt autoIt, ILogger logger, int x, int y, int width, int height)
     : this(new Rectangle(x, y, width, height))
 {
     _autoIt = autoIt;
     _logger = logger;
 }
Exemplo n.º 26
0
        public InBonusGame(IAutoIt autoIt, IAssetCatalog assetCatalog, ILogger logger)
            : base(autoIt,
                assetCatalog,
                logger,
                @"Images\ALL\Game\bonus_game\BG_Background.jpg",
                266, 372, 74, 38,
                256, 363, 95, 56)
        {
            var one = new List<TemplateCoordinate>
            {
                new TemplateCoordinate(520, 17, 23, 24),
                new TemplateCoordinate(562, 23, 23, 24),
                new TemplateCoordinate(602, 29, 23, 24)
            };

            var two = new List<TemplateCoordinate>
            {
                new TemplateCoordinate(328, 170, 23, 24),
                new TemplateCoordinate(367, 164, 23, 24),
                new TemplateCoordinate(414, 158, 23, 24),
                new TemplateCoordinate(457, 152, 23, 24)
            };

            var three = new List<TemplateCoordinate>
            {
                new TemplateCoordinate(500, 277, 23, 24),
                new TemplateCoordinate(543, 283, 23, 24),
                new TemplateCoordinate(581, 288, 23, 24), // TODO: double check this area
                new TemplateCoordinate(623, 295, 23, 24)
            };

            var four = new List<TemplateCoordinate>
            {
                new TemplateCoordinate(288, 440, 23, 24),
                new TemplateCoordinate(330, 434, 23, 24),
                new TemplateCoordinate(372, 428, 23, 24),
                new TemplateCoordinate(414, 422, 23, 24),
                new TemplateCoordinate(457, 416, 23, 24),
            };

            var five = new List<TemplateCoordinate>
            {
                new TemplateCoordinate(24, 430, 23, 24),
                new TemplateCoordinate(65, 430, 23, 24),
                new TemplateCoordinate(106, 430, 23, 24),
                new TemplateCoordinate(145, 430, 23, 24),
                new TemplateCoordinate(187, 430, 23, 24),
                new TemplateCoordinate(227, 430, 23, 24)
            };

            var rightTemplate = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\bonus_game\BG_LetterTile_Angle_Right_Up.jpg")
                .Copy(new Rectangle(6, 10, 34, 32));

            var leftTemplate = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\bonus_game\BG_LetterTile_Angle_Left_Up.jpg")
                .Copy(new Rectangle(10, 8, 34, 32));

            var straightTemplate = assetCatalog
                .GetCompositeImage(@"Images\ALL\Game\bonus_game\BG_LetterTile_Angle_Straight_Up.jpg")
                .Copy(new Rectangle(7, 8, 34, 34));

            var bonusOne = new TemplateSearchArea(leftTemplate, new Rectangle(499, 8, 153, 61));
            var bonusTwo = new TemplateSearchArea(rightTemplate, new Rectangle(311, 144, 190, 69));
            var bonusThree = new TemplateSearchArea(leftTemplate, new Rectangle(478, 265, 198, 77));
            var bonusFour = new TemplateSearchArea(rightTemplate, new Rectangle(273, 412, 230, 81));
            var bonusFive = new TemplateSearchArea(straightTemplate, new Rectangle(10, 419, 252, 45));

            _letterGroups.Add(new KeyValuePair<TemplateSearchArea,List<TemplateCoordinate>>(bonusOne, one));
            _letterGroups.Add(new KeyValuePair<TemplateSearchArea,List<TemplateCoordinate>>(bonusTwo, two));
            _letterGroups.Add(new KeyValuePair<TemplateSearchArea,List<TemplateCoordinate>>(bonusThree, three));
            _letterGroups.Add(new KeyValuePair<TemplateSearchArea,List<TemplateCoordinate>>(bonusFour, four));
            _letterGroups.Add(new KeyValuePair<TemplateSearchArea,List<TemplateCoordinate>>(bonusFive, five));
        }