public override void DoPostConfigureComplete(GameObject go) { SolidConduitTemperatureSensor conduitTemperatureSensor = go.AddOrGet <SolidConduitTemperatureSensor>(); conduitTemperatureSensor.Threshold = 280f; conduitTemperatureSensor.ActivateAboveThreshold = true; conduitTemperatureSensor.rangeMin = 0f; conduitTemperatureSensor.rangeMax = 9999f; }
private void OnCopySettings(object data) { GameObject gameObject = (GameObject)data; if (gameObject == null) { return; } SolidConduitTemperatureSensor component = gameObject.GetComponent <SolidConduitTemperatureSensor>(); if (component == null) { return; } Threshold = component.Threshold; ActivateAboveThreshold = component.ActivateAboveThreshold; }