PauseActionAttributeclass

A button of your game's own on the pause menu, along its top bar beside Resume - a vote, a scoreboard, a "back to the lobby". Put it on a static method that takes nothing; pressing the button calls it.

object→Attribute→PauseActionAttribute
Namespace
Sandbox
Assembly
Sandbox.Engine
Declaration
public sealed class Sandbox.PauseActionAttribute : System.Attribute

Constructors1

Showing 1 constructors

Properties5

Showing 5 properties

public bool Sandbox.PauseActionAttribute.DismissOnPress { get; set; }PUBLICGETSET

Close the pause menu once it's pressed, back to the game - for an action that opens something of the game's own, or only makes sense played.

Returns:bool—

public string Sandbox.PauseActionAttribute.Icon { get; set; }PUBLICGETSET

A Material icon name to go with it, or null for none.

Returns:string—

public int Sandbox.PauseActionAttribute.Order { get; set; }PUBLICGETSET

Where it goes among the game's other actions - lower first.

Returns:int—

public string Sandbox.PauseActionAttribute.Tooltip { get; set; }PUBLICGETSET

Shown when the button's hovered, or null for none.

Returns:string—

On this page