public void Exorcised() { GameObject newObj = Instantiate(playerPrefab, transform.position, transform.rotation); GameObject camera = GameObject.Find("CameraManager"); CameraManager cm = camera.GetComponent <CameraManager>(); cm.Follow(newObj.transform); abmoorInput = new AbmoorAIInput(); abmoorMovement = new AbmoorMovement(abmoorInput, transform, abmoorSettings, abmoorRaycastController); }
public void Possessed() { abmoorInput = new ControllerInput(); abmoorMovement = new AbmoorMovement(abmoorInput, transform, abmoorSettings, abmoorRaycastController); }
private void Awake() { abmoorRaycastController = GetComponent <AbmoorRaycastController>(); abmoorInput = abmoorSettings.UseAi ? new AbmoorAIInput() as IInput : new ControllerInput(); abmoorMovement = new AbmoorMovement(abmoorInput, transform, abmoorSettings, abmoorRaycastController); }