public override void OnEnterState(GameController gameController) { arrow = gameController.GetArrow(); //arrow.SetActive(true); arrow.SetActive(false); direction = Camera.main.transform.forward; direction.y = 0; direction.Normalize(); Disc disc = gameController.GetDisc(); disc.SetColliderEnabled(false); ThrowController throwController = gameController.GetThrowController(); disc.Grab(throwController.heldTransform); Vector3 holePosition = gameController.GetCurrentHole().HoleTrigger.transform.position; throwController.SetTargetPosition(holePosition + new Vector3(0, 1, 0)); SetArrowTransform(gameController); }
public void StartThrow(GvrControllerInputDevice controller) { discVelocity = Vector3.zero; disc.Grab(heldTransform); Zeros(accelMag); }