Example #1
0
 private void FixedUpdate()
 {
     if (attractorPlanet)
     {
         attractorPlanet.Attract(playerTransform);
     }
 }
Example #2
0
 void FixedUpdate()
 {
     if ((attractorPlanet) & inGravityField == true)
     {
         attractorPlanet.Attract(playerTransform);
     }
 }
Example #3
0
 // Update is called once per frame
 void Update()
 {
     if (isOnPlanet && canMove && planet != null)
     {
         planet.Attract(playerTransform, playerBody);
     }
     PlayerController();
 }
Example #4
0
 void FixedUpdate()
 {
     if (attractorPlanet)
     {
         attractorPlanet.Attract(playerTransform);
     }
     GetComponent <Rigidbody>().constraints = RigidbodyConstraints.FreezeRotation;
 }