codeAPI Reference

s&box IToolInfo: Tool information display interface

calendar_today May 12, 2026 schedule ~1 min read person PatrickJr verified 50

IToolInfo API Reference

IToolInfo is an interface for providing tool information display in the UI, such as in the spawn menu or tool selector.

Type Signature

CSHARP
public interface IToolInfo : IValid
{
    string Name { get; }
    string Description { get; }
    string PrimaryAction => null;
    string SecondaryAction => null;
    string ReloadAction => null;
}

Properties

Usage

Implement this interface on ToolMode classes or other tool-related components:

CSHARP
public class BalloonTool : ToolMode, IToolInfo
{
    public string Name => "Balloon";
    public string Description => "Spawn balloons that float upward";
    public string PrimaryAction => "Spawn Balloon";
    public string SecondaryAction => "Remove Balloon";
}

Notes

  • Inherits from IValid for validity checking.
  • Used by the UI to display tool information to players.
  • Default implementations return null for action descriptions.
  • Action descriptions are typically shown in HUD or tooltips.
Was this helpful?