void PlayerDead()
{
if (_playerDead) return;
_playerDead = true;
//Disable the animator - actually - create particle.
// Disable the movement.
//_animator.SetFloat(_hash.speedFloat, 0f);
//playerMovement.enabled = false;
var particles = (GameObject) Instantiate(DeathParticles, transform.position, Quaternion.identity);
Destroy(particles,7);
// Reset the player sighting to turn off the alarms.
_lastPlayerSighting.position = _lastPlayerSighting.resetPosition;
// Stop the footsteps playing.
//GetComponent<AudioSource>().Stop();
//Stop animations (or maybe after death? good use for AnimationStateBehavior)
_animator.enabled = false;
//Disable physics
GetComponent<Rigidbody>().isKinematic = true;
//Hide vampire
var vampire = transform.FindChild("vamp_complete");
if (!vampire)
{
Debug.LogError("Couldn't find child vampire object of VampKid character controller");
}
vampire.gameObject.SetActive(false);
var cameraRig = GameObject.FindGameObjectWithTag(Tags.cameraRig);
cameraRig.GetComponent<FreeLookCam>().PlayerDiedCameraAction();
//Lerp camera vertical, move up a bit
//pivot it to 90
//y to 20
//Disable input for free look rig
//or maybe just lerp to look upwards to sky (moon?)
}