private void Awake() { Instance = this; PB = FindObjectOfType <p_PlayerBeing>(); /*oProfile = GetComponent<PostProcessingBehaviour>().profile; * * profile = new PostProcessingProfile(); * profile.vignette.enabled = oProfile.vignette.enabled; * profile.vignette.settings = oProfile.vignette.settings; * profile.antialiasing.enabled = oProfile.antialiasing.enabled; * profile.antialiasing.settings = oProfile.antialiasing.settings; * profile.motionBlur.enabled = oProfile.motionBlur.enabled; * profile.motionBlur.settings = oProfile.motionBlur.settings; * profile.eyeAdaptation.enabled = oProfile.eyeAdaptation.enabled; * profile.eyeAdaptation.settings = oProfile.eyeAdaptation.settings; * profile.bloom.enabled = oProfile.bloom.enabled; * profile.bloom.settings = oProfile.bloom.settings; * profile.colorGrading.enabled = oProfile.colorGrading.enabled; * profile.colorGrading.settings = oProfile.colorGrading.settings; * profile.chromaticAberration.enabled = oProfile.chromaticAberration.enabled; * profile.chromaticAberration.settings = oProfile.chromaticAberration.settings; * profile.grain.enabled = oProfile.grain.enabled; * profile.grain.settings = oProfile.grain.settings; * profile.depthOfField.enabled = oProfile.depthOfField.enabled; * profile.depthOfField.settings = oProfile.depthOfField.settings; * * GetComponent<PostProcessingBehaviour>().profile = profile;*/ }
protected void Awake() { rect = GetComponent <RectTransform>(); fill = transform.Find("Fill").GetComponent <RectTransform>(); pb = FindObjectOfType <p_PlayerBeing>(); switch (stat) { case StatToLink.Health: curDisplayValue = (pb.CurHealth / pb.MaxHealth); break; case StatToLink.Blood: curDisplayValue = (pb.CurBlood / pb.MaxBlood); break; case StatToLink.Madness: curDisplayValue = (pb.CurMadness / pb.MaxMadness); break; } }
protected void Awake() { linkedBase = GetComponent <p_Base>(); linkedBeing = GetComponent <p_PlayerBeing>(); }