private void _ShowAboutDialog() { bool showOnStart = (bool)editorSettings.GetSetting("mono/editor/show_info_on_start"); aboutDialogCheckBox.Pressed = showOnStart; aboutDialog.PopupCentered(); }
public void OpenPopup() { var popup = new AcceptDialog(); popup.SizeFlagsHorizontal = (int)Control.SizeFlags.ExpandFill; popup.SizeFlagsVertical = (int)Control.SizeFlags.ExpandFill; popup.PopupExclusive = true; popup.WindowTitle = "Configure snap"; var container = new VBoxContainer(); var snapSpin = new SpinBox(); snapSpin.MinValue = 0; snapSpin.MaxValue = 99; snapSpin.Step = 0.0001f; snapSpin.Value = snapLength; snapSpin.Connect("value_changed", this, "SetSnapLength"); var snapHBox = new HBoxContainer(); var snapLabel = new Label(); snapLabel.Text = "Snap length"; snapHBox.AddChild(snapLabel); snapHBox.AddChild(snapSpin); container.AddChild(snapHBox); popup.AddChild(container); popup.Connect("popup_hide", popup, "queue_free"); baseControl.AddChild(popup); popup.PopupCentered(new Vector2(200, 100)); }
public override void _Ready() { loader = GetNode<Loader>("SpaceHUD/MarginContainer/HBoxContainer/Loader"); tutorial = GetNode<AcceptDialog>("SpaceHUD/Tutorial"); if (!PlayerData.Instance.ViewedTutorial) { tutorial.PopupCentered(); PlayerData.Instance.ViewedTutorial = false; GD.Print("Tutorial is popped"); } }
public override void _Ready() { loader = GetNode <Loader>("SpaceHUD/MarginContainer/HBoxContainer/Loader"); tutorial = GetNode <AcceptDialog>("SpaceHUD/Tutorial"); upgradeMenu = GetNode <CanvasLayer>("SpaceHUD").GetNode <UpgradeMain>("MainUpgradeMenu"); upgradeMenu.Visible = false; if (!PlayerData.Instance.ViewedTutorial) { tutorial.PopupCentered(); PlayerData.Instance.ViewedTutorial = false; GD.Print("Tutorial is popped"); } }
public override void _Ready() { story = GetNode <AcceptDialog>("CanvasLayer/Story"); CheckChildren(GetChildren()); foreach (TileMap map in tileMaps) { MakeTileCollisionShapes(map); } if (!PlayerData.Instance.ViewedStory) { story.PopupCentered(); PlayerData.Instance.ViewedStory = false; } }
public void DisplayHelpPopup() { _helpDialog.PopupCentered(); switch (_alchemyStage) { case AlchemyStage.MortarPestle: { switch (_mortarPestleStage) { case MortarPestleStage.PickReagents: { _helpDialog.DialogText = "Select your reagents from the list to the right."; break; } case MortarPestleStage.Crush: { _helpDialog.DialogText = "Crush up the reagents with the mortar and pestle! Just pick up the pestle and start smashing."; break; } } break; } case AlchemyStage.Calcinator: { break; } case AlchemyStage.Alembic: { break; } case AlchemyStage.Retort: { break; } } }
public override void _Ready() { story = GetNode <AcceptDialog>("CanvasLayer/Story"); CheckChildren(GetChildren()); foreach (TileMap map in tileMaps) { MakeTileCollisionShapes(map); } if (!PlayerData.Instance.ViewedStory) { story.PopupCentered(); PlayerData.Instance.ViewedStory = false; GD.Print("Story is popped"); } Signals.PublishRoverFuelChangedEvent(); }
private void ShowAlert(string text) { _alertDialog.DialogText = text; _alertDialog.PopupCentered(); }
public void ShowErrorDialog(string message, string title = "Error") { _errorDialog.Title = title; _errorDialog.DialogText = message; _errorDialog.PopupCentered(); }