private void Start() { playerAttacking = false; hasScythe = true; spinUnlocked = false; throwUnlocked = false; spinUnlocked = false; gameOn = true; scytheController = scythe.GetComponent <ScytheController>(); origScytheLocPos = scythe.transform.localPosition; origScytheLocRot = scythe.transform.localEulerAngles; }
//Calling on the CharacterController Component void Start() { //Debug.DrawRay(transform.position, transform.right, Color.red); controller = GetComponent <Rigidbody>(); controller.mass = _GAME.playerMass; scytheController = scythe.GetComponentInParent <ScytheController>(); bodyCollider = GetComponent <CapsuleCollider>(); bodyCentre = bodyCollider.center; bodyHeight = bodyCollider.height; //replaced by animation later. bodyMesh = transform.GetChild(0); bodyScale = bodyMesh.localScale; bodyPos = bodyMesh.localPosition; }