Exemplo n.º 1
0
    void OnTriggerEnter(Collider other)
    {
        PCInputManager player = other.gameObject.GetComponent <PCInputManager>();

        if (player != null)
        {
            AddValue(player);

            Destroy(this.gameObject);
        }
    }
Exemplo n.º 2
0
    void OnTriggerExit(Collider other)
    {
        PCInputManager pc = other.gameObject.GetComponent <PCInputManager>();

        if (collidedWith != null && collidedWith.GetInstanceID().Equals(pc.GetInstanceID()))
        {
            collidedWith = null;
            spawner.AssignNewTarget(null);
            pulse = false;
        }
    }
Exemplo n.º 3
0
    void OnTriggerEnter(Collider other)
    {
        if (collidedWith != null)
        {
            return;
        }

        PCInputManager pc = other.gameObject.GetComponent <PCInputManager>();

        if (pc == null)
        {
            return;
        }

        spawner.AssignNewTarget(pc.gameObject);
        pulse = true;
    }
Exemplo n.º 4
0
 public abstract void AddValue(PCInputManager gameObject);
Exemplo n.º 5
0
 public override void AddValue(PCInputManager player)
 {
     player.AddValue(value);
 }
Exemplo n.º 6
0
 // Use this for initialization
 void Start()
 {
     parent = this.gameObject.GetComponentInParent <PCInputManager>();
     team   = parent.team;
 }