/// <summary> /// Popup has been close and hotspot has not been presented by a multi hotspot. /// </summary> private void ActionCompleteController() { //#if UNITY_WEBGL && !UNITY_EDITOR // WebGLCommunication._instance.CallWeb("Close " + hotspotDataModel.actionType); //#endif controller.PopUpClosed(); if (firstOpen) { controller.HotspotHasBeenViewed(); firstOpen = false; } switch (hotspotDataModel.clickAction) { case OnClickAction.Disable: IsInteractable = true; break; case OnClickAction.Hide: gameObject.SetActive(true); break; case OnClickAction.Delete: gameObject.SetActive(true); transform.localScale = Vector3.zero; StartCoroutine(DestroyOnEndOfFrame()); break; } }
public void ActionComplete() { controller.PopUpClosed(); //First Open if (firstOpen) { controller.HotspotHasBeenViewed(); firstOpen = false; } //Click Action switch (ClickAction) { case OnClickAction.Disable: IsInteractable = true; break; case OnClickAction.Hide: RevealHotspot(); break; case OnClickAction.Delete: Destroy(gameObject); break; } //Disable Children DisableChildHotpsots(); EnableNonHotspotChildren(); for (int i = 0; i < transform.childCount; i++) { var hotspot = transform.GetChild(i).GetComponent <IHotspot>(); if (hotspot != null) { hotspot.EnableInteractivity(); } } }