Skip to content

Interface

The interface is a set of widgets on one CommonUI root, scaled as a whole by the player's options and styled from one asset.

In the game

Every panel is a window that folds to its title bar, unfolds on hover, drags freely and can be pinned. It keeps its place, its fold and its pin from one game to the next, and never leaves the screen. The player cannot resize a window: each keeps the size it was authored with.

Around the windows:

  • Messages stack in a short queue at the bottom of the screen.
  • The clock sits in the top right, with the day and date, the hour, the air temperature, the weather, and the speed buttons for a host playing alone.
  • The weapon bar runs along the bottom.
  • Each player sees the name of every other survivor above their head, never their own, and not through walls.

The object you would use with E can name itself above it, next to the key's glyph (Open Door, Search Fridge, Climb over Fence). This prompt is off by default. The hints of a piece being placed always show.

The INTERFACE page of the options scales the whole interface from 75 to 150 % and sets the text size (Normal, Large, Larger). Both are kept in the player's local profile. At 130 % scale and above, a window left where it opens by default can overlap another.

On a gamepad, inside a window, the focus stops at the window bar, so the rows of a window and the context menu still need the mouse.

The assets

Content/ZombieSurvival/Blueprints/UI/WBP_UIRoot holds four stacks, GameLayer, GameMenuLayer, MenuLayer and ModalLayer, all inside the safe zone. The name tag is WBP_NameTag and the death screen WBP_DeathScreen.

Most widgets, the menus included, take their colours, fonts and backgrounds from one style asset, DataAssets/UI/DA_UIStyle. It is a PDA_UIStyle, next to its class and not in a Childs/ folder, with four named tables:

Table Keys What it holds
Colors 45 background, panel, borders, text ramps, need colours, selection, warnings, menu, death screen, name tag, skill colours, ConditionBar, SourceIconTint
Sizes 22 text sizes, row and title bar heights, icon size, widths, paddings
Fonts 28 Title, HUD, Body, Small, one per kind of menu, sheet, context menu, Controls window and name tag text, and the two sizes of a radial entry
Brushes 35 panel, plate, title bar, rows, slots, the four button states, glyphs, menu backdrops (MenuBackdrop draws M_UI_MenuGradient over T_UI_MenuBackdrop), the three states of a loot source tile

Most widgets have a Style field whose default is DA_UIStyle, so a value changed in Colors, Fonts or Brushes re-themes the HUD, every window, every list row and every menu at once. A new key added to DA_UIStyle does nothing until a widget reads it.

Asset Property Default What it does
DA_UIStyle Colors, Fonts, Brushes 45, 28, 35 keys colours, fonts and backgrounds of most widgets
DA_UIStyle Sizes.TitleBarHeight 28 title bar height of every window, read at runtime
DA_UIStyle Sizes.SourceTilePadding 1 margin around each picture of the loot source column, read at runtime
DA_UIStyle ContainerKinds, FallbackContainerIcon, GroundSourceName, GroundSourceIcon 23 rows; "Ground" the pictures and names of the loot source column
Blueprints/UI/WBP_PanelFrame FrameWidth, MinBodyHeight, ExpandedBodyHeight per window, set inside WBP_HUD the real window geometry
WBP_InteractPrompt bShowTargetPrompt off names the object you would use with E above it
local profile interface scale, text size 75 to 150 %; Normal, Large or Larger the player's own scale and text size, set on the INTERFACE page

Only two Sizes keys move anything

TitleBarHeight and SourceTilePadding are read at runtime. Changing the other twenty Sizes keys changes nothing on screen. Window geometry comes from WBP_PanelFrame.

Change it

  • To re-theme the whole interface, edit Colors, Fonts and Brushes in DA_UIStyle. Change the UI theme is a worked example.
  • To restyle one widget alone, point its Style at another style asset. Restyle the interface lists which widgets follow the style.
  • To resize a window, change the WBP_PanelFrame settings of its instance in WBP_HUD.
  • To show the prompt that names the object under E, tick bShowTargetPrompt on WBP_InteractPrompt.
  • To change the texts, follow Translate the game. Every displayed text is ready to translate.