Ejemplo n.º 1
0
        private void SetProperiesToCurrentLog()
        {
            TypeOfRotation typeOfRotation = UnityEngine.Random.Range(0f, 1f) < _gameProperies.chanceOfRotationWithPeriod ? TypeOfRotation.PeriodRotation : TypeOfRotation.Normal;

            _currentLogRotator.SetTypeOfRotation(typeOfRotation);
            _currentLogRotator.SetPeriodOfRotation(GameController.instance.gameProperies.rotationgPeriod);


            _currentLogRotator.SetRotationSpeed(
                UnityEngine.Random.Range(_gameProperies.minRotationSpeedOfLog, _gameProperies.maxRotationSpeedOfLog));
            _currentLogRotator.SetRotationSide(UnityEngine.Random.Range(0, 2) == 1);
            _currentLogRotator.SetTimeOnStartRotation(
                UnityEngine.Random.Range(_gameProperies.minTimeOnStartRotation, _gameProperies.maxTimeOnStartRotation));
        }
Ejemplo n.º 2
0
 public void SetTypeOfRotation(TypeOfRotation typeOfRotation = TypeOfRotation.Normal)
 {
     this._typeOfRotation = typeOfRotation;
 }