Exemplo n.º 1
0
 //Calculate the distance between the player and lancer
 void GetDistance()
 {
     distance = Vector3.Distance(lancer.getPlayerPosition(), lancer.transform.position);
 }
Exemplo n.º 2
0
 //distance between player and lancer
 public float GetDistance()
 {
     return(distance = Vector3.Distance(lancer.getPlayerPosition(), lancer.detectPlayerSphere.position));
 }