public void TemperatureHazard(TemperatureEffect inHazard) { // This is for changing character effects this._hazardEffect = inHazard; if (this._currentTemperature > this._zero) { this._currentTemperature -= this.temperatureEffect; } else { this._currentTemperature = this._zero; } if (this._tempFX) { this.SetTempFX(); } }
private void Awake() { this.burningEffect = this.InstansiateEffect(this.burningPrefab); this.freezingEffect = this.InstansiateEffect(this.freezingPrefab); base.GetComponent <TemperatureVisualControllerComponent>().listeners.Add(this); }