private void Push(IJamView view) { StopLoitering(); _subview = view; _subview.Init(); _clickUi.Add(_subview.ClickUiBranch); }
public void Init() { _tutorial = new ExclusiveChoicesTutorial(); _subView = new ScanView(_person, DisableDialogueControls, InitDialogueOptions, () => !_isPresentingToUser); _subView.Init(); _endConversationButton = new ImageTextButton(new Transform2(new Rectangle(-684, 960, 1380, 64)), _onFinished, "Ok, great.", "Convo/DialogueButton", "Convo/DialogueButton-Hover", "Convo/DialogueButton-Press") { TextColor = Color.White, TextTransform = new Transform2(new Vector2(60, 960), new Size2(1380 - 684, 64)), TextAlignment = HorizontalAlignment.Left }; _characterView = new CharacterView(_person, () => _shouldShowDialogueControls); _playerView = new PlayerCharacterView(() => _shouldShowDialogueControls); _onNextDialogueElement = x => { _characterView.UpdateDialogue(x); _playerView.UpdateDialogue(x); }; if (_person.IsImmediatelyTalking()) { _person.StartImmediatelyTalking(StartDialogue); } else { InitDialogueOptions(); } }
private void InitUiElements() { _subview = new NoSubView(); _objectives = new ObjectivesView(); _objectives.Init(); _investigateRoomBranch = new ClickUIBranch("Location Investigation", 1); _locationNameLabel = UiLabels.HeaderLabel(_location.Name, Color.White); _clickUi = new ClickUI(); _tutorialBranch = new ClickUIBranch("Tutorial", 25); _tutorialBranch.Add(_objectives.TutorialButton); _clickUi.Add(_tutorialBranch); }
private void StartLoitering() { GameObjects.Characters.GetPeopleAt(_location.Value) .Select(x => new ImageButton(x.Image, x.Image, x.Image, x.WhereAreYouStanding(), () => TalkTo(x), () => x != _talkingTo)).ToArray().ForEachIndex((b, i) => b.TooltipText = GameResources.GetCharacterName(GameObjects.Characters.GetPeopleAt(_location.Value)[i].Value)); _subview = new NoSubView(); _clickUi.Clear(); _isPresentingToUser = false; _talkingTo = null; UpdateClues(); _clickUi.Add(_tutorialBranch); _clickUi.Add(_investigateRoomBranch); _clickUi.Add(GameObjects.Hud.HudBranch); _isLoitering = true; }
protected void AddUi(IJamView v) { _clickUi.Add(v.ClickUiBranch); _visuals.Add(v); _automata.Add(v); }