Пример #1
0
        private void cmdCastle1_Click(object sender, EventArgs e)
        {
            Button btn = (Button)sender;

            Heroes.Core.Player player = null;
            if (btn.Equals(cmdCastle1))
                player = (Heroes.Core.Player)_players[0];
            else
                player = (Heroes.Core.Player)_players[1];

            Heroes.Core.Castle.frmCastle f = new Heroes.Core.Castle.frmCastle();
            f.ShowDialog((Heroes.Core.Town)player._castles[0]);
        }
Пример #2
0
 void f_VisitingCastle(Heroes.Core.Map.frmMap.VisitingCastleEventArg e)
 {
     using (Heroes.Core.Castle.frmCastle f = new Heroes.Core.Castle.frmCastle())
     {
         f.ShowDialog(e._castle);
     }
 }
Пример #3
0
        private void cmdCastle_Click(object sender, EventArgs e)
        {
            Button btn = (Button)sender;

            Heroes.Core.Castle.frmCastle f = new Heroes.Core.Castle.frmCastle();
            f.ReadOnly = this._readOnly;
            f.ShowDialog((Heroes.Core.Town)this._currentPlayer._castles[0]);

            if (_currentHero != null)
            {
                _currentHero.AddAttributeToArmies();
            }
        }