Knowledge base
Knowledge base
Knowledge base
Free, anonymous browsing of Unreal Engine Blueprint examples, node references, and best practices. The same content the WoalzCraft plugin uses to generate Blueprints.
23 results for toggle
Variables: MenuWidget (UserWidget subclass), bIsMenuOpen (bool). InputAction MenuKey → FlipFlop → A (open): Branch(MenuWidget is null) → True: CreateWidget(WBP_Menu) → SetVariable(MenuWidget) → AddToViewport → SetInputMode_UIOnly → SetShowMouseCursor(true) → SetVariable(bIsMenuOpen=true). B (close): MenuWidget → RemoveFromParent → SetInputMode_GameOnly → SetShowMouseCursor(false) → SetVariable(bIsMenuOpen=false). Key: Always check IsValid(MenuWidget) before calling RemoveFromParent. SetInputMode_UIOnly is on PlayerController. Don't re-create widget if it exists — just show/hide.
Alternates between A and B output pins on each execution. Useful for toggle switches and ping-pong logic.
Macro. Enter only passes through when gate is open.
GateUE 5.0, 5.1, 5.2, 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoESlateVisibility: Visible, Collapsed, Hidden, HitTestInvisible, SelfHitTestInvisible.
Set VisibilityUE 5.0, 5.1, 5.2, 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoPattern: WBP_MainMenu with WidgetSwitcher containing panels (Main, Options, Credits). Buttons: OnClicked → SetActiveWidgetIndex(WidgetSwitcher, PanelIndex). Play button: RemoveFromParent → OpenLevel(GameMap). Quit: QuitGame. Level BP BeginPlay: CreateWidget(MainMenu) → AddToViewport → SetInputModeUIOnly → SetShowMouseCursor(true).
SetVisibilityUE 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoPattern: Door actor with BoxTrigger, DoorMesh, Timeline(Alpha 0→1 over 1s). BeginOverlap → PlayFromStart(Timeline). EndOverlap → Reverse(Timeline). Timeline Update: Lerp(ClosedRotation, OpenRotation, Alpha) → SetRelativeRotation(DoorMesh). For sliding: Lerp locations instead of rotations.
Set Visibility (Component)UE 5.0, 5.1, 5.2, 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoSetInputMode_UIOnlyUE 5.3, 5.4, 5.5, 5.6, 5.7updated 2mo agoPattern: CreateWidget(WBP_LoadingScreen) → AddToViewport(ZOrder=100) → LoadStreamLevel or OpenLevel(NewMapName). For async: AsyncLoadLevel → OnCompleted → RemoveFromParent(LoadingWidget). Store persistent data in GameInstance before transition. Use Seamless Travel for multiplayer.