Пример #1
0
        private void CalcNextGoal()
        {
            if (pendingGoals.Count > 0)
            {
                ++pendingIndex;
                if (pendingIndex >= pendingGoals.Count)
                {
                    pendingGoals.Shuffle();
                    pendingIndex = 0;
                }
                currentGoal_ = pendingGoals[pendingIndex];
            }
            else
            {
                currentGoal_ = SensorKind.ObjetivoFinal;
            }

            // Select player object
            listener.transform.SetParent(transform);
            listener.transform.localPosition = Vector3.zero;
            currentPlayer_?.Hide();
            currentPlayer_ = null;
            foreach (BallController c in playerObjects)
            {
                if (c.Goal == currentGoal_)
                {
                    currentPlayer_ = c;
                }
            }

            cam.GetComponent <AudioListener>().enabled = false;
            listener.enabled = true;
        }
Пример #2
0
 public SensorInformation(SensorKind kind)
 {
     this.Id               = Guid.NewGuid();
     this.Name             = "";
     this.LogicalDeviceId  = null;
     this.PhysicalDeviceId = null;
     this.LocationId       = Guid.Empty;
     this.Kind             = kind;
 }
Пример #3
0
 public SensorInformation(Guid id, SensorKind kind) : this(kind)
 {
     this.Id = id;
 }