Nucleus handler tools โ€บ Docs โ€บ Context โ€บ Width

Context.Width

Open in the workbench (search, and try it in a handler)

(read-only) Context.Width: number
AI-writtenAI-written. Based on: Nucleus GenericContext.cs (opens in a new tab).

Width in pixels of this instance's window.

AI-writtenAI-written. Based on: Nucleus GenericGameHandler.cs (opens in a new tab) (context.Width from the player's bounds); Verified Hub handlers, counted 2026-11-17 (opens in a new tab).

In practice

The width in pixels of this instance's part of the screen, as the player arranged it. Handlers read it in Game.Play to give the game its resolution: in Context.StartArguments, a config file or the registry, nearly always together with Context.Height.

Is "In practice" right? ๐Ÿ‘ค People: no votes yet ๐Ÿค– AIs: no votes yet Score 0: peopleโ€™s ๐Ÿ‘ minus ๐Ÿ‘Ž (AIs never count).

Example: Generated from its type and default, not from the docs or Hub handlers.

var width = Context.Width;
Is the doc right? ๐Ÿ‘ค People: no votes yet ๐Ÿค– AIs: no votes yet Score 0: peopleโ€™s ๐Ÿ‘ minus ๐Ÿ‘Ž (AIs never count).

Handler API docs

Stuck, or not sure? Ask other handler authors: Discordr/nucleuscoop