Ejemplo n.º 1
0
 public UserControl GetVisualisationUserControl(IConfigurable configuration)
 {
     _antWarsViewModel = new AntWarsViewModel();
     _movementService  = new MovementService(_antWarsViewModel);
     _botService       = new BotService(_antWarsViewModel);
     return(new AntWarsUserControl(_antWarsViewModel));
 }
Ejemplo n.º 2
0
        public static void CreateBattleground(int rows, int collumns, AntWarsViewModel antWarsViewModel)
        {
            _antWarsViewModel = antWarsViewModel;

            _antWarsViewModel.RowCount           = rows;
            _antWarsViewModel.ColumnCount        = collumns;
            _antWarsViewModel.BattlegroundWidth  = _antWarsViewModel.RowCount * BattlefieldUnitHeigth;
            _antWarsViewModel.BattlegroundHeigth = _antWarsViewModel.ColumnCount * BattlefieldUnitWidth;

            InitiateBattlefield();
        }
Ejemplo n.º 3
0
        public static void CreateBattleground(int rows, int collumns, AntWarsViewModel antWarsViewModel)
        {
            _antWarsViewModel = antWarsViewModel;

            _antWarsViewModel.RowCount           = rows;
            _antWarsViewModel.ColumnCount        = collumns;
            _antWarsViewModel.BattlegroundWidth  = _antWarsViewModel.RowCount * BATTLEFIELD_UNIT_HEIGTH;
            _antWarsViewModel.BattlegroundHeigth = _antWarsViewModel.ColumnCount * BATTLEFIELD_UNIT_WIDTH;

            InitiateBattlefield();
        }
Ejemplo n.º 4
0
 public AntWarsUserControl(AntWarsViewModel viewModel)
 {
     InitializeComponent();
     DataContext = viewModel;
 }
Ejemplo n.º 5
0
 public MovementPerformer(AntWarsViewModel antWarsViewModel)
 {
     _antWarsViewModel = antWarsViewModel;
 }
Ejemplo n.º 6
0
 public BotService(AntWarsViewModel antWarsViewModel)
 {
     _antWarsViewModel = antWarsViewModel;
 }
Ejemplo n.º 7
0
 public MovementService(AntWarsViewModel antWarsViewModel)
 {
     _antWarsViewModel     = antWarsViewModel;
     _listOfMissilesToFire = new List <MissileModel>();
 }