Пример #1
0
        public void TestIsAvailable(int baseCountTick)
        {
            var tickController = new TickСontroller(baseCountTick);

            for (var i = 0; i < baseCountTick; i++)
            {
                Assert.False(tickController.Check());
            }
            Assert.True(tickController.Check());
        }
Пример #2
0
 protected BaseMalefactor(int health, Vector position, State state, double speed, int countTick, int cost)
 {
     Health         = health;
     Position       = position;
     State          = state;
     IsDead         = false;
     Direction      = Direction.Left;
     Speed          = speed;
     Cost           = cost;
     tickСontroller = new TickСontroller(countTick);
 }
Пример #3
0
 public BaseHero(UnitParameters parametres, Vector position, State state)
 {
     Health = parametres.Health;
     if (parametres.Characteristics.Where(c => c.Name == "Reload").Any())
     {
         Reload = parametres.Reload;
     }
     Position       = position;
     State          = state;
     IsDead         = false;
     tickСontroller = new TickСontroller(Reload);
 }
Пример #4
0
 public Wave(List <IMalefactor> malefactors, int timeToStart)
 {
     Malefactors    = malefactors;
     tickСontroller = new TickСontroller(timeToStart);
 }
Пример #5
0
 public GemFactory()
 {
     tickСontroller = new TickСontroller(150);
     random         = new Random();
 }