void OnTriggerExit(Collider other) { // Controller for Simulator, Side for HTC Vive if (myObject == null) { return; } if (other.name.Contains("Controller") || other.name.Contains("Side")) { cnt--; if (cnt <= 0) { show = false; ShowNameOnTouch.FreeText(myObject); } } else { UCE_Heatable heatable = other.GetComponent <UCE_Heatable>(); if (heatable && heatable.type == UCE_Heatable.Type.Normal) { insideHeatable = null; } } }
void OnTriggerExit(Collider other) { if (type == Type.Burner) { UCE_Heatable heatable = other.GetComponent <UCE_Heatable>(); if (heatable) { heatable.isHeating = false; childHeatable = null; } } }
void OnTriggerEnter(Collider other) { if (type == Type.Burner) { UCE_Heatable heatable = other.GetComponent <UCE_Heatable>(); if (heatable) { // This is required because the following corner case can happen: // Enter -> Enter -> Exit -> Exit if (childHeatable) { childHeatable.isHeating = false; childHeatable = null; } childHeatable = heatable; if (isHeating == true) { heatable.isHeating = false; } } } }
void OnTriggerEnter(Collider other) { // Controller for Simulator, Side for HTC Vive if (other.name.Contains("Controller") || other.name.Contains("Side")) { cnt++; // When using dropper, this function might be triggered twice in a row, // so we need this to ensure the name text before can disapper properly if (show) { return; } myObject = ShowNameOnTouch.AllocateText(); show = true; } else { UCE_Heatable heatable = other.GetComponent <UCE_Heatable>(); if (heatable && heatable.type == UCE_Heatable.Type.Normal) { insideHeatable = heatable; } } }
// Use this for initialization void Start() { heatable = transform.GetComponent <UCE_Heatable>(); airTransmit = transform.GetComponent <AirTransmit>(); }
public static void Register(UCE_Heatable heatable) { burner = heatable; }