Exemple #1
0
 public PeopleViewForm()
 {
     InitializeComponent();
     this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
     people = new List<RivalState>();
     virtualRegion = new VirtualRegion(this);
     virtualRegion.AddRegion(new PictureRegion(1, 41, 40, 70, 70, 1, VirtualRegionCellType.People, 0));
     for (int i = 0; i < 20; i++)
     {
         int xoff = (i%5)*cardWidth+19;
         int yoff = (i / 5) * cardHeight+159;
         SubVirtualRegion region = new PictureAnimRegion(i + 2, xoff, yoff, cardWidth, cardHeight, i + 2, VirtualRegionCellType.People, 0);
         region.AddDecorator(new RegionTextDecorator(0, 45, 9));
         virtualRegion.AddRegion(region);
     }
     types = GetPeopleAvailTypes();
     for (int i = 0; i < types.Length; i++)
     {
         int xoff = i * 26 + 19;
         int yoff = 125;
         virtualRegion.AddRegion(new ButtonRegion(i + 30, xoff, yoff, 24, 24, i + 30, string.Format("MiniPeopleType{0}.JPG", types[i]), string.Format("MiniPeopleType{0}On.JPG", types[i])));
     }
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
     virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClick);
 }
Exemple #2
0
 private void buttonStart_Click(object sender, System.EventArgs e)
 {
     if (isButtonFirstClick)
     {
         for (int i = GameConstants.BattleInitialCardCount-1; i >= 0; i--)
         {
             if (!keepCard[i])
             {
                 player.CardManager.GetNextCardAt(i + 1);
             }
         }
         InstallCards();
         region = null;
         isButtonFirstClick = false;
         bitmapButton1.ForeColor = Color.Red;
         bitmapButton1.Text = @"进入游戏";
         Invalidate();
     }
     else
     {
         if (StartClicked != null)
         {
             StartClicked();
         }
     }
 }
Exemple #3
0
        public SelectJobForm()
        {
            InitializeComponent();
            NeedBlackForm = true;
            this.bitmapButtonSelect.ImageNormal = PicLoader.Read("ButtonBitmap", "ButtonBack2.PNG");
            bitmapButtonSelect.Font = new Font("宋体", 8 * 1.33f, FontStyle.Regular, GraphicsUnit.Pixel);
            bitmapButtonSelect.ForeColor = Color.White;
            bitmapButtonSelect.IconImage = TaleofMonsters.Core.HSIcons.GetIconsByEName("oth2");
            bitmapButtonSelect.IconSize = new Size(16, 16);
            bitmapButtonSelect.IconXY = new Point(8, 5);
            bitmapButtonSelect.TextOffX = 8;

            selectPanel = new NLSelectPanel(8, 38, 154, 400, this);
            selectPanel.ItemHeight = 35;
            selectPanel.SelectIndexChanged += selectPanel_SelectedIndexChanged;
            selectPanel.DrawCell += selectPanel_DrawCell;

            this.nlPageSelector1 = new NLPageSelector(this, 10, 321, 150);
            nlPageSelector1.PageChange += nlPageSelector1_PageChange;

            jobDes = new ColorWordRegion(180, 70, 320, "宋体", 10, Color.White);

            virtualRegion = new VirtualRegion(this);
            PictureRegion region = new PictureRegion(1, 178, 266, 48, 48, 1, VirtualRegionCellType.HeroSkill, 0);
            region.AddDecorator(new RegionBorderDecorator(Color.DodgerBlue));
            virtualRegion.AddRegion(region);

            virtualRegion.AddRegion(new PictureRegion(2, 238, 266, 48, 48, 2, VirtualRegionCellType.Card, 0));
            virtualRegion.AddRegion(new PictureRegion(3, 298, 266, 48, 48, 3, VirtualRegionCellType.Card, 0));
            virtualRegion.AddRegion(new PictureRegion(4, 358, 266, 48, 48, 4, VirtualRegionCellType.Card, 0));
            virtualRegion.RegionEntered += virtualRegion_RegionEntered;
            virtualRegion.RegionLeft += virtualRegion_RegionLeft;
     }
Exemple #4
0
 public void Init()
 {
     virtualRegion = new VirtualRegion(parent);
     virtualRegion.AddRegion(new PictureAnimRegion(1, x + 11, y + 19, 56, 56, 1, VirtualRegionCellType.Item, 0));
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #5
0
 public void Init(int type)
 {
     priceType = type;
     virtualRegion = new VirtualRegion(parent);
     virtualRegion.AddRegion(new PictureAnimRegion(1, x + 5, y + 8, 40, 40, 1, VirtualRegionCellType.Card, 0));
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #6
0
        public void Init(int idx)
        {
            index = idx;

            virtualRegion = new VirtualRegion(parent);
            virtualRegion.AddRegion(new PictureRegion(1, x + 3, y + 3, 76, 75, 1, VirtualRegionCellType.Achieve, 0));
            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
        }
Exemple #7
0
 public void Init()
 {
     virtualRegion = new VirtualRegion(parent);
     virtualRegion.AddRegion(new SubVirtualRegion(1, x + 12, y + 14, 64, 84, 1));
     virtualRegion.AddRegion(new ButtonRegion(2, x + 55, y + 102, 17, 17, 2, "BuyIcon.PNG", "BuyIconOn.PNG"));
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
     virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClicked);
 }
Exemple #8
0
 public PopBuyProduct()
 {
     InitializeComponent();
     BackgroundImage = PicLoader.Read("System", "DeckChoose.PNG");
     FormBorderStyle = FormBorderStyle.None;
     virtualRegion = new VirtualRegion(this);
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #9
0
        private List<int> itemTypeList = new List<int>();//存下道具的类型

        public TaskResultForm()
        {
            InitializeComponent();
            this.bitmapButtonClose2.ImageNormal = PicLoader.Read("ButtonBitmap", "CancelButton.JPG");
            bitmapButtonClose2.NoUseDrawNine = true;
            virtualRegion = new VirtualRegion(this);
            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
        }
Exemple #10
0
        public CardSelector()
        {
            InitializeComponent();

            region = new VirtualRegion(this);
            region.AddRegion(new SwitchButtonRegion(1, 0, 0, 120, 120, 1, "ErrorButton.PNG", ""));
            region.AddRegion(new SwitchButtonRegion(2, 200, 0, 120, 120, 2, "ErrorButton.PNG", ""));
            region.AddRegion(new SwitchButtonRegion(3, 400, 0, 120, 120, 3, "ErrorButton.PNG", ""));
            region.RegionClicked+=region_RegionClicked;
        }
Exemple #11
0
        public CardBagForm()
        {
            InitializeComponent();
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");

            vRegion = new VirtualRegion(this);
            
            vRegion.RegionEntered += OnVRegionEntered;
            vRegion.RegionLeft += OnVRegionLeft;
            vRegion.RegionClicked += OnVRegionClick;
        }
Exemple #12
0
 public NpcTaskBeginForm()
 {
     InitializeComponent();
     colorWord = new ColorWordRegion(22, 97, 268, "宋体", 10, Color.White);
     virtualRegion = new VirtualRegion(this);
     virtualRegion.AddRegion(new SubVirtualRegion(1, 22, 230, 258, 20, 1));
     virtualRegion.AddRegion(new SubVirtualRegion(2, 22, 250, 258, 20, 2));
     virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClicked);
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #13
0
        public NpcDigForm()
        {
            InitializeComponent();
            colorWord = new ColorWordRegion(22, 77, 268, "宋体", 10, Color.White);
            virtualRegion = new VirtualRegion(this);
            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);

            bitmapButtonPick.ImageNormal = PicLoader.Read("ButtonBitmap", "PickButton.JPG");
            this.bitmapButtonClose2.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
        }
Exemple #14
0
 public LevelUpForm()
 {
     InitializeComponent();
     this.bitmapButtonC1.ImageNormal = PicLoader.Read("ButtonBitmap", "LevelButton.JPG");
     virtualRegion = new VirtualRegion(this);
     virtualRegion.AddRegion(new SubVirtualRegion(1, 5, 5, 40, 40, 1));
     virtualRegion.AddRegion(new SubVirtualRegion(2, 5, 55, 40, 40, 2));
     virtualRegion.AddRegion(new SubVirtualRegion(3, 155, 5, 40, 40, 3));
     virtualRegion.AddRegion(new SubVirtualRegion(4, 155, 55, 40, 40, 4));
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #15
0
 public CreatePlayerForm()
 {
     InitializeComponent();
     FormBorderStyle = FormBorderStyle.None;
     myCursor = new HSCursor(this);
     virtualRegion = new VirtualRegion(this);
     virtualRegion.AddRegion(new SubVirtualRegion(1, 141, 159, 24, 24, 1));
     virtualRegion.AddRegion(new SubVirtualRegion(2, 141, 192, 24, 24, 2));
     virtualRegion.AddRegion(new SubVirtualRegion(3, 141, 225, 24, 24, 3));
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #16
0
 public void InitTasks()
 {
     virtualRegion = new VirtualRegion(this);
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
     int id = 1;
     tids = TaskBook.GetTaskByLevels();
     foreach (int tid in tids)
     {
         TaskConfig taskConfig = ConfigData.GetTaskConfig(tid);
         virtualRegion.AddRegion(new PictureRegion(id, 24 + taskConfig.Position.X * 32, 82 + taskConfig.Position.Y * 32, 28, 28, id, VirtualRegionCellType.Task, tid));
         id++;
     }
 }
Exemple #17
0
 internal BattleResultForm()
 {
     InitializeComponent();
     NeedBlackForm = true;
     this.bitmapButtonClose2.ImageNormal = PicLoader.Read("ButtonBitmap", "CancelButton.JPG");
     bitmapButtonClose2.NoUseDrawNine = true;
     virtualRegion = new VirtualRegion(this);
     virtualRegion.AddRegion(new PictureAnimRegion(1, 102, 270, 60, 60, 1, VirtualRegionCellType.Item, 0));
     virtualRegion.AddRegion(new PictureAnimRegion(2, 172, 270, 60, 60, 2, VirtualRegionCellType.Item, 0));
     virtualRegion.AddRegion(new PictureAnimRegion(3, 242, 270, 60, 60, 3, VirtualRegionCellType.Item, 0));
     virtualRegion.AddRegion(new PictureAnimRegion(4, 312, 270, 60, 60, 4, VirtualRegionCellType.Item, 0));
     virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #18
0
        public CardDropViewForm()
        {
            InitializeComponent();
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
            bitmapButtonClose.NoUseDrawNine = true;
            this.bitmapButtonNext.ImageNormal = PicLoader.Read("ButtonBitmap", "NextButton.JPG");
            bitmapButtonNext.NoUseDrawNine = true;
            this.bitmapButtonPre.ImageNormal = PicLoader.Read("ButtonBitmap", "PreButton.JPG");
            bitmapButtonPre.NoUseDrawNine = true;
            tempImage = new Bitmap(cardWidth * xCount, cardHeight*yCount);

            virtualRegion = new VirtualRegion(this);

            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
        }
 public MagicBookViewForm()
 {
     InitializeComponent();
     this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
     virtualRegion = new VirtualRegion(this);
     int xOff = 15;
     int yOff = 40;
     AddBookRegion(1, xOff + 55, yOff + 35, 51000129, "卡牌手册");
     AddBookRegion(2, xOff + 55 + 90, yOff + 35,  53000014, "技能手册");
     AddBookRegion(3, xOff + 55 + 180, yOff + 35, 53000098,"对手分析");
     AddBookRegion(4, xOff + 55, yOff + 35 + 120, 52000061,"材料大全");
     AddBookRegion(5, xOff + 55 + 90, yOff + 35 +120, 53000110, "掉落系谱");
     virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClicked);
     virtualRegion.RegionEntered+=new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
     virtualRegion.RegionLeft+=new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
 }
Exemple #20
0
        public CardDetail(UserControl control, int x, int y, int height)
        {
            card = SpecialCards.NullCard;
            parent = control;
            X = x;
            Y = y;
            Width = 200;
            Height = height;

            virtualRegion = new VirtualRegion(control);
            virtualRegion.AddRegion(new SubVirtualRegion(1, x + 60, y + 170, 24, 24, 1));
            virtualRegion.AddRegion(new SubVirtualRegion(2, x + 88, y + 170, 24, 24, 2));
            virtualRegion.AddRegion(new PictureRegion(3, x + 116, y + 170, 24, 24, 3, VirtualRegionCellType.CardQual, 0));
            virtualRegion.AddRegion(new PictureRegion(4, x + 146, y + 25, 24, 24, 4, VirtualRegionCellType.Job, 0));
            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
        }
Exemple #21
0
        private Equip vEquip; //所有装备的属性

        public EquipmentForm()
        {
            InitializeComponent();
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
            vRegion = new VirtualRegion(this);
            var r1 = new PictureRegion(1, 413, 69, 64, 64, 1, VirtualRegionCellType.Equip, UserProfile.InfoEquip.Equipon[0]);
            r1.AddDecorator(new RegionBorderDecorator(Color.Yellow));//头盔
            vRegion.AddRegion(r1);
            r1 = new PictureRegion(2, 374, 151, 40, 40, 2, VirtualRegionCellType.Equip, UserProfile.InfoEquip.Equipon[1]);
            r1.AddDecorator(new RegionBorderDecorator(Color.Yellow));//武器
            vRegion.AddRegion(r1);
            r1 = new PictureRegion(3, 425, 151, 40, 40, 3, VirtualRegionCellType.Equip, UserProfile.InfoEquip.Equipon[2]);
            r1.AddDecorator(new RegionBorderDecorator(Color.Yellow));//防具
            vRegion.AddRegion(r1);
            r1 = new PictureRegion(4, 476, 151, 40, 40, 4, VirtualRegionCellType.Equip, UserProfile.InfoEquip.Equipon[3]);
            r1.AddDecorator(new RegionBorderDecorator(Color.Yellow));//饰品
            vRegion.AddRegion(r1);

            vRegion.AddRegion(new SubVirtualRegion(10, 147, 107, 46, 44, 10));
            vRegion.AddRegion(new SubVirtualRegion(11, 200, 107, 46, 44, 11));
            vRegion.AddRegion(new SubVirtualRegion(12, 253, 107, 46, 44, 12));
            vRegion.AddRegion(new SubVirtualRegion(13, 306, 107, 46, 44, 13));
            vRegion.AddRegion(new SubVirtualRegion(14, 147, 170, 46, 44, 14));
            vRegion.AddRegion(new SubVirtualRegion(15, 200, 170, 46, 44, 15));
            vRegion.AddRegion(new SubVirtualRegion(16, 253, 170, 46, 44, 16));

            for (int i = 0; i < 60; i++)
            {
                var region = new PictureRegion(20 + i, 38 + (i % 15) * 32, 227 + (i / 15) * 32, 32, 32, 20+i, VirtualRegionCellType.Equip, UserProfile.InfoEquip.Equipoff[i]);
             //   region.AddDecorator(new RegionBorderDecorator(region, Color.Yellow));
                vRegion.AddRegion(region);
            }

            vRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClicked);
            vRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            vRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
            tempImage = new Bitmap(160, 160);
            selectTar = -1;
            myCursor = new HSCursor(this);

            popMenuEquip = new PopMenuEquip();
            popContainer = new PoperContainer(popMenuEquip);
            popMenuEquip.PoperContainer = popContainer;
            popMenuEquip.Form = this;
        }
        public TreasureWheelForm()
        {
            InitializeComponent();
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
            this.bitmapButtonC1.ImageNormal = PicLoader.Read("ButtonBitmap", "ButtonBack2.PNG");
            bitmapButtonC1.Font = new Font("宋体", 8 * 1.33f, FontStyle.Regular, GraphicsUnit.Pixel);
            bitmapButtonC1.ForeColor = Color.White;
            bitmapButtonC1.IconImage = TaleofMonsters.Core.HSIcons.GetIconsByEName("wep4");
            bitmapButtonC1.IconSize = new Size(16, 16);
            bitmapButtonC1.IconXY = new Point(4, 5);
            bitmapButtonC1.TextOffX = 8;
            backImage = PicLoader.Read("MiniGame", "t4.JPG");

            points= new Point[18];
#region 初始化位置
            points[0] = new Point(15, 10);
            points[1] = new Point(65, 10);
            points[2] = new Point(115, 10);
            points[3] = new Point(165, 10);
            points[4] = new Point(215, 10);
            points[5] = new Point(265, 10);
            points[6] = new Point(265, 55);
            points[7] = new Point(265, 100);
            points[8] = new Point(265, 145);
            points[9] = new Point(265, 190);
            points[10] = new Point(215, 190);
            points[11] = new Point(165, 190);
            points[12] = new Point(115, 190);
            points[13] = new Point(65, 190);
            points[14] = new Point(15, 190);
            points[15] = new Point(15, 145);
            points[16] = new Point(15, 100);
            points[17] = new Point(15, 55);
#endregion

            virtualRegion = new VirtualRegion(panelBack);
            for (int i = 0; i < points.Length; i++)
            {
                virtualRegion.AddRegion(new PictureAnimRegion(i, points[i].X, points[i].Y, 40, 40, 1, VirtualRegionCellType.Item, ConfigDatas.ConfigData.GetTreasureWheelConfig(i + 1).Item)); 
            }
           
            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
        }
Exemple #23
0
        public MGUpToNumber()
        {
            type = (int)SystemMenuIds.GameUpToNumber;
            InitializeComponent();

            virtualRegion = new VirtualRegion(this);
            for (int i = 0; i < 4; i++)
            {
                ButtonRegion region = new ButtonRegion(i + 1, 60 + 55 * i, 310, 50, 50, i + 1, "GameUpToNumber1.PNG", "GameUpToNumber1On.PNG");
                region.AddDecorator(new RegionTextDecorator(10, 20, 10));
                virtualRegion.AddRegion(region);
            }
            virtualRegion.SetRegionDecorator(1, 0, "牛肉");
            virtualRegion.SetRegionDecorator(2, 0, "蜂蜜");
            virtualRegion.SetRegionDecorator(3, 0, "黄油");
            virtualRegion.SetRegionDecorator(4, 0, " 水");

            virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClicked);
        }
Exemple #24
0
        public MGThreeBody()
        {
            type = (int)SystemMenuIds.GameThreeBody;
            InitializeComponent();

            virtualRegion = new VirtualRegion(this);
            for (int i = 0; i < 5; i++)
            {
                ButtonRegion region = new ButtonRegion(i + 1, 40 + 55 * i, 310, 50, 50, i + 1, string.Format("GameSanTi{0}.PNG", i + 1), string.Format("GameSanTi{0}On.PNG", i + 1));
                region.AddDecorator(new RegionTextDecorator(10, 30, 10));
                virtualRegion.AddRegion(region);
            }
            virtualRegion.SetRegionDecorator(1, 0, "浸泡");
            virtualRegion.SetRegionDecorator(2, 0, "脱水");
            virtualRegion.SetRegionDecorator(3, 0, "医疗");
            virtualRegion.SetRegionDecorator(4, 0, "农耕");
            virtualRegion.SetRegionDecorator(5, 0, "科研");
            
            virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClicked);
        }
Exemple #25
0
        public CardShopViewForm()
        {
            InitializeComponent();
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
            this.bitmapButtonRefresh.ImageNormal = PicLoader.Read("ButtonBitmap", "LearnButton.JPG");
            this.nlPageSelector1 = new NLPageSelector(this, 371, 438, 150);
            nlPageSelector1.PageChange += nlPageSelector1_PageChange;

            vRegion = new VirtualRegion(this);
            for (int i = 0; i < 3; i++)
            {
                SubVirtualRegion subRegion = new ButtonRegion(i + 1, 16 + 45 * i, 40, 42, 23, i + 1, "ShopTag.JPG", "ShopTagOn.JPG");
                subRegion.AddDecorator(new RegionTextDecorator(8, 7, 9, Color.White, false));
                vRegion.AddRegion(subRegion);
            }
            vRegion.SetRegionDecorator(1, 0, "怪物");
            vRegion.SetRegionDecorator(2, 0, "武器");
            vRegion.SetRegionDecorator(3, 0, "魔法");
            vRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClick);
        }
Exemple #26
0
        public MergeWeaponForm()
        {
            InitializeComponent();
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
            virtualRegion = new VirtualRegion(this);
            virtualRegion.AddRegion(new PictureAnimRegion(1, 295, 100, 60, 60, 1, VirtualRegionCellType.Equip, 0));
            virtualRegion.AddRegion(new PictureAnimRegion(2, 200, 259, 40, 40, 3, VirtualRegionCellType.Item, 0));
            virtualRegion.AddRegion(new PictureAnimRegion(3, 410, 259, 40, 40, 4, VirtualRegionCellType.Item, 0));
            virtualRegion.AddRegion(new PictureAnimRegion(4, 270, 259, 40, 40, 5, VirtualRegionCellType.Item, 0));
            virtualRegion.AddRegion(new PictureAnimRegion(5, 340, 259, 40, 40, 6, VirtualRegionCellType.Item, 0));

            virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClicked);
            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);

            selectPanel = new NLSelectPanel(8, 34, 154, 400, this);
            selectPanel.ItemHeight = 50;
            selectPanel.SelectIndexChanged += selectPanel_SelectedIndexChanged;
            selectPanel.DrawCell += new NLSelectPanel.SelectPanelCellDrawHandler(selectPanel_DrawCell);
        }
Exemple #27
0
        public GameShopViewForm()
        {
            InitializeComponent();
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");
            this.nlPageSelector1 = new ControlPlus.NLPageSelector(this, 365, 365, 150);
            nlPageSelector1.PageChange += nlPageSelector1_PageChange;
            productIds = new List<int>();
            virtualRegion = new VirtualRegion(this);
            for (int i = 0; i < 4; i++)
            {
                SubVirtualRegion subRegion = new ButtonRegion(i + 1, 16 + 45 * i, 39, 42, 23, i + 1, "ShopTag.JPG", "ShopTagOn.JPG");
                subRegion.AddDecorator(new RegionTextDecorator(8,7,9,Color.White, false));
                virtualRegion.AddRegion(subRegion);
            }
            virtualRegion.SetRegionDecorator(1, 0, "礼包");
            virtualRegion.SetRegionDecorator(2, 0, "战斗");
            virtualRegion.SetRegionDecorator(3, 0, "道具");
            virtualRegion.SetRegionDecorator(4, 0, "神器");

            virtualRegion.RegionClicked += new VirtualRegion.VRegionClickEventHandler(virtualRegion_RegionClick);
        }
Exemple #28
0
        public void Init(int idx)
        {
            index = idx;

            switch (index)
            {
                case 0:
                case 1: backColor = Color.Black; break;
                case 2:
                case 3: backColor = Color.FromArgb(0, 0, 60); break;
                case 4:
                case 5: backColor = Color.FromArgb(0, 60, 0); break;
                case 6:
                case 7: backColor = Color.FromArgb(60, 60, 0); break;
            }

            virtualRegion = new VirtualRegion(parent);
            virtualRegion.AddRegion(new PictureAnimRegion(1, x + 5, y + 8, 40, 40, 1, VirtualRegionCellType.Item, 0));
            virtualRegion.RegionEntered += new VirtualRegion.VRegionEnteredEventHandler(virtualRegion_RegionEntered);
            virtualRegion.RegionLeft += new VirtualRegion.VRegionLeftEventHandler(virtualRegion_RegionLeft);
        }
Exemple #29
0
        public BattleForm()
        {
            InitializeComponent();
            NeedBlackForm = true;
            this.bitmapButtonClose.ImageNormal = PicLoader.Read("ButtonBitmap", "CloseButton1.JPG");

            vRegion = new VirtualRegion(this);
            vRegion.RegionClicked += OnVRegionClick;
            vRegion.RegionEntered += virtualRegion_RegionEntered;
            vRegion.RegionLeft += virtualRegion_RegionLeft;

            cardSelector1.StartClicked += buttonStart_Click;
#if DEBUG
            cardList2.Visible = true;
#endif
            myCursor = new HSCursor(this);
            lifeClock1.Init();
            lifeClock2.Init();
            lifeClock1.IsLeft = true;
            lifeClock2.IsLeft = false;
        }