Skip to content

Restyle the interface

One Data Asset, DA_UIStyle, holds the look of the HUD, the windows and the menus. A change there reaches every widget that follows it, without opening a widget Blueprint. The tutorial Change the UI theme is a worked example.

Steps

  1. Open Content/ZombieSurvival/DataAssets/UI/DA_UIStyle. It sits next to its class PDA_UIStyle, not in a Childs/ folder.
  2. Change values in its four tables (Colors, Sizes, Fonts, Brushes) or in its loot source settings.
  3. Save, and press Play.

To restyle one widget alone, point that widget's Style field at another style asset.

The four tables

Table Keys What it holds
Colors 45 Background, panel, borders, text ramps, the four need colours, row striping, selection, warnings, the menu, death screen, name tag and skill colours, ConditionBar (the bar under an item with a state), and SourceIconTint.
Sizes 22 Text sizes, row and title bar heights, icon size, window width, column widths, paddings. Only two are read at runtime.
Fonts 28 Title, HUD, Body, Small, then one per kind of text of the menus, the character sheet, the context menu, the Controls window and the name tags (MenuTitle, MenuButton, ColumnHead, SheetTitle...), and the two sizes of a radial entry (RadialLabel, RadialLabelSmall).
Brushes 35 Panel, plate, title bar, rows and the selected row, slots, the four button states, the item category and navigation glyphs, the backdrops and frame of the menus, and the three states of a loot source tile.

SourceIconTint is the tint laid over the pictures of the loot source column. It ships white, so each picture keeps its own colours.

The two sizes that are read

  • TitleBarHeight (28): the height of every window's title bar. Raise it to give every panel more room for descenders.
  • SourceTilePadding (1): the margin around each picture in the loot source column.

The other twenty are reference data. They describe the layout the widgets were drawn to, and changing one changes nothing on screen. The window geometry comes from Settings on Blueprints/UI/WBP_PanelFrame (FrameWidth, MinBodyHeight, ExpandedBodyHeight), set per window instance inside WBP_HUD.

The menu backdrop

MenuBackdrop, in Brushes, draws Materials/UI/M_UI_MenuGradient: dark on the left behind the menu column, clear on the right. Its parameters are LeftOpacity, RightOpacity, FadeStart and FadeEnd.

Under it lies Textures/UI/T_UI_MenuBackdrop, a 3840 × 2160 painted picture that every menu screen draws, from the main menu to character creation. To put your own key art there, reimport over that texture, so that every reference keeps pointing at it. Keep it soft and dark where the text stands (the left half, and the whole width behind the traits page), and keep its compression on BC7: the default compression bands a smooth gradient.

The loot source tiles

Brush What it draws
SourceTile The tile at rest, transparent.
SourceTileHover The tile under the mouse: an opaque black fill and a thin grey outline.
SourceTileSelected The active source: the same black fill and a 2-unit orange outline, kept while the mouse is over that tile.
ButtonPressed A tile being clicked.

Keep those fills dark if you restyle them. Several furniture pictures are light beige and are hard to read on a mid-grey fill.

The loot source column

Next to the four tables, four settings drive the loot source column.

Setting What it does
ContainerKinds One row per kind of furniture: a Mesh (the CabinetMesh a container shows), a DisplayName (the name in the loot window's title and in the tile's tooltip) and an Icon (the picture on the tile). The row is found by mesh, so every container built on that mesh gets the same picture and name, in every map. 23 rows ship. Pine Hollow does not use them all; the others are ready for a container made from that mesh.
FallbackContainerIcon The generic picture, shown in place of an empty tile by a container whose mesh has no row, or whose row has no icon. Without a row the container also keeps its own DisplayName.
GroundSourceName, GroundSourceIcon The name ("Ground") and picture of the ground tile, which always comes last in the column.

To give a new piece of furniture its own picture and name, follow the icon rules in Build a house, then add a row to ContainerKinds.

Which widgets follow it

Most widget Blueprints have a Style field whose default is DA_UIStyle. They take their fonts, text colours and backgrounds from it. Many of them name, in an ApplyStyle function, the Fonts and Colors keys each text uses.

Where Widgets
HUD WBP_HUD, and WBP_PanelFrame, the window frame every panel is built from
Window bodies WBP_InventoryWindow, WBP_NearbyWindow, WBP_ControlsWindow, WBP_CharacterWindow, WBP_CraftWindow, WBP_BuildWindow
Crafting window WBP_CraftCategory, WBP_RecipeRow, WBP_RepairRow, WBP_RecipeDetail
Build window WBP_BuildCategory, WBP_BuildRow, WBP_BuildDetail
Inventory and loot WBP_ItemSlot (the inventory row), WBP_BagSection (a worn bag), WBP_ItemMenuEntry (one entry of the item menu), WBP_NearbySource (one tile of the loot source column)
Character window WBP_ProtectionPage and WBP_TemperaturePage, two of its tabs
Other HUD widgets WBP_WeaponSlot, WBP_EquipSlot, WBP_HealthPanel, WBP_SkillFamilyHeader, WBP_SkillRow, WBP_SkillBox, WBP_TraitRow, WBP_SleepOverlay, WBP_ActionQueueRow, WBP_MessageQueue, WBP_InteractPrompt, WBP_ContextAction, WBP_ControlRow, WBP_RadialMenu, WBP_RadialEntryLabel, WBP_NameTag
Menus WBP_MainMenu, WBP_HostMenu, WBP_GameOptionsMenu, WBP_GameOptionRow, WBP_JoinMenu, WBP_SessionRow, WBP_PauseMenu, WBP_DeathScreen

These widgets hold no text: WBP_UIRoot, WBP_HealthWindow, WBP_ActionQueue, WBP_ItemMenu, WBP_StatusRow, WBP_HandFrame, and WBP_ActionBar, whose progress bar keeps its own fill colour. WBP_Tooltip, the body of a tooltip, holds a text but no reference to the style asset.

Widgets not named here are not documented either way. Open one and look for a Style field.

Test it

  1. Change a colour in Colors, for example the panel background, and save.
  2. Open Content/ZombieSurvival/Maps/L_World and press Play.
  3. Press Tab, C, H and P: every window shows the new colour.
  4. For the menus, open Maps/L_Boot and press Play.
  5. For the pause menu, play L_Boot as a Standalone Game (the arrow next to Play), start a world and press Esc. In the editor's own Play, Esc stops the game.

If it does not work

  • A key you added to a table does nothing: no widget reads it yet.
  • A row shows an empty tile: its icon points at a texture that was deleted or moved outside the editor. An icon must point to a texture that still exists.