// Update is called once per frame void FixedUpdate() { // Updates the texture if we are displaying Temp if (_metal.isThermDisplayed) { _metal.UpdateTextureThermals(); } // Performance optimizer, does not compute for all metals ! // if((T > (_Tatm + 0.1) && T > (_Tatm - 0.1)) && (Tnew > (_Tatm + 0.1) && Tnew > (_Tatm - 0.1))) {// Ice mat must change temp > 0.2 K otherwise no update will be done... if (Time.time >= _lastReaction + _deltaT) { UpdateT(); _lastReaction = Time.time; } // Ensures that _delta is bigger than the frame rate ! _deltaT = Mathf.Max(Time.deltaTime, 0.15f); } }