/// <summary> /// Updates the 5th hint. Returns true if the 5th room objective is complete. /// </summary> /// <returns></returns> private static bool CompletedHint5() { bool completedObjective = true; DemoCharacter.hints[4] = ""; foreach (var state in EditorFullscreenState.fullscreenState.window) { if (state.IsFullscreen && state.WindowType != EditorFullscreenState.MainWindowType && EditorDisplay.ClosestToPoint(state.FullscreenAtPosition).Bounds.Contains(EditorMainWindow.position.center)) { completedObjective = false; var fullscreenOption = state.FullscreenOptions; string openAtPos, keysDownString; GetInfoForFullscreenOption(fullscreenOption, out openAtPos, out keysDownString); var windowName = state.WindowType.ToString(); if (windowName.Contains(".")) { windowName = windowName.Split(".".ToCharArray())[1]; } windowName = EditorFullscreenSettings.FormatCamelCaseName(windowName); DemoCharacter.hints[4] += "Press " + keysDownString + " to close the " + windowName; if (fullscreenOption.openAtPosition == EditorFullscreenSettings.OpenFullscreenAtPosition.AtMousePosition) { DemoCharacter.hints[4] += "\n(mouse must be hovering over the window)"; } DemoCharacter.hints[4] += "\n"; } } return(completedObjective); }