Exemplo n.º 1
0
        private InfoView AddPlayerAttribute(string Text, int TipWidth)
        {
            InfoViewEx e = new InfoViewEx(TipWidth);

            e.Text   = Text;
            e.Bounds = new Rectangle(0, 20 * (PlayerAttributeNumbers++), 210, 20);
            PlayerAttributePanel.Controls.Add(e);
            return(e);
        }
Exemplo n.º 2
0
        public PagePanel_MainPage(int Width, int Height) : base(Width, Height)
        {
            TextFont = new Font("Arial", 10);
            using (var s = Assembly.GetExecutingAssembly().GetManifestResourceStream("QTRHacker.NewDimension.Res.Image.cross.png"))
                CrossImage = Image.FromStream(s);

            PlayerArrayBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 60, Width, 20),
                Text   = MainForm.CurrentLanguage["PlayerArrayAddress"]
            };
            Controls.Add(PlayerArrayBaseAddressInfoView);

            CurrentPlayerBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 80, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerAddress"]
            };
            Controls.Add(CurrentPlayerBaseAddressInfoView);

            CurrentPlayerInventoryBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 100, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerInvAddress"]
            };
            Controls.Add(CurrentPlayerInventoryBaseAddressInfoView);

            CurrentPlayerArmorBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 120, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerArmorAddress"]
            };
            Controls.Add(CurrentPlayerArmorBaseAddressInfoView);

            CurrentPlayerDyeBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 140, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerDyeAddress"]
            };
            Controls.Add(CurrentPlayerDyeBaseAddressInfoView);

            CurrentPlayerMiscBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 160, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerMiscAddress"]
            };
            Controls.Add(CurrentPlayerMiscBaseAddressInfoView);

            CurrentPlayerMiscDyeBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 180, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerMiscDyeAddress"]
            };
            Controls.Add(CurrentPlayerMiscDyeBaseAddressInfoView);

            CurrentPlayerBuffTypeBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 200, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerBuffAddress"]
            };
            Controls.Add(CurrentPlayerBuffTypeBaseAddressInfoView);

            CurrentPlayerBuffTimeBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 220, Width, 20),
                Text   = MainForm.CurrentLanguage["MyPlayerBuffTimeAddress"]
            };
            Controls.Add(CurrentPlayerBuffTimeBaseAddressInfoView);

            CurrentPlayerFirstItemBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 240, Width, 20),
                Text   = MainForm.CurrentLanguage["InvFirstItemAddress"]
            };
            Controls.Add(CurrentPlayerFirstItemBaseAddressInfoView);

            Terraria_Main_Update_BaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 260, Width, 20),
                Text   = MainForm.CurrentLanguage["Terraria_Main_Update"]
            };
            Controls.Add(Terraria_Main_Update_BaseAddressInfoView);

            SignHeadBaseAddressInfoView = new InfoViewEx(220)
            {
                Bounds = new Rectangle(0, 280, Width, 20),
                Text   = MainForm.CurrentLanguage["SignHead"]
            };
            Controls.Add(SignHeadBaseAddressInfoView);



            RefreshButton           = new Button();
            RefreshButton.FlatStyle = FlatStyle.Flat;
            RefreshButton.ForeColor = Color.White;
            RefreshButton.Text      = MainForm.CurrentLanguage["FetchAddressesAgain"];
            RefreshButton.Bounds    = new Rectangle(Width - 130, Height - 40, 120, 30);
            RefreshButton.Click    += (s, e) =>
            {
                if (HackContext.GameContext == null)
                {
                    return;
                }
                InitializeAddresses();
            };
            Controls.Add(RefreshButton);
        }