public void DisplayIndicatorIfNotDisplayedYet(IndicatorID id) { if (!hasIndicatorBeenDisplayed(id)) { DisplayIndicator(id, true); } }
public bool hasIndicatorBeenDisplayed(IndicatorID id) { TutorialIndicator t = GetTutorialIndicatorById(id); bool hasBeenDisplayed = false; if (t != null) { hasBeenDisplayed = t.passed; } return(hasBeenDisplayed); }
public TutorialIndicator(IndicatorID id, string name, string text, GameObject panel, bool atStart, IndicatorID indicatorToDisplayOnTouch) { this.id = id; this.name = name; //this.text = text; this.panel = panel; this.atStart = atStart; this.passed = false; this.indicatorToDisplayOnTouch = indicatorToDisplayOnTouch; Initialize(); }
public void TutorialIndicatorTouched(IndicatorID id) { //Debug.Log("Tutorial Indicator Touched [" + id + "]"); DisplayIndicator(id, false); IndicatorID nextElementID = GetTutorialIndicatorById(id).indicatorToDisplayOnTouch; if (nextElementID != 0) { DisplayIndicatorIfNotDisplayedYet(nextElementID); } }
public void DisplayIndicator(IndicatorID id, bool enable) { TutorialIndicator t = GetTutorialIndicatorById(id); if (t != null) { t.panel.SetActive(enable); if (enable) { t.passed = true; } } }
public TutorialIndicator GetTutorialIndicatorById(IndicatorID id) { TutorialIndicator t = null; foreach (TutorialIndicator tutoIndi in availableTutorialIndicators) { if (tutoIndi.id == id) { t = tutoIndi; break; } } return(t); }