Example #1
0
    private new void Awake()
    {
        base.Awake();
        DontDestroyOnLoad(gameObject);

        RaceOptions = RaceOptions.DefaultRaceOptions;
    }
Example #2
0
        public AnimalRace(RaceOptions options, ICurrencyService currency, RaceAnimal[] availableAnimals)
        {
            this._currency     = currency;
            this._options      = options;
            this._animalsQueue = new Queue <RaceAnimal>(availableAnimals);
            this.MaxUsers      = availableAnimals.Length;

            if (this._animalsQueue.Count == 0)
            {
                CurrentPhase = Phase.Ended;
            }
        }