Skip to content

User Interfaces

Overview

The plugin API can be used to create new interfaces and manipulate existing ones, ranging from changing colours and styles, to contents.

Default Property Values

Unless otherwise stated, values for certain UI properties present across multiple types in the interface system share the same default value, in particular:

  • Colours and tints - White (Vector4.new(1.0) or 0xFFFFFFFF) by default
  • Alpha - Fully opaque (1.0) by default

Components

A component represents a single element of the game interface, ranging from an input field, to a button, or a grid for example.

Components can be split into two categories:

  • Static - hardcoded components defined via resource files
  • Dynamic - components created at runtime via scripts

Both categories behave in the same way and support the exact same components, however they're identified slightly differently. Dynamic components are always created on a static parent component, and are associated with two IDs, a category ID and a dynamic ID, which combined represented a unique ID on the parent static component.

Info

Unlike dynamic components, static components cannot be removed at runtime.

The RuneScape Client API can only be used to create Dynamic components but can be used to access and modify both Static and Dynamic components.

Info

Multiple components can have the same category ID and dynamic ID as long as they're static parent differs

Valid ID Ranges
  • Category IDs can range from 0 to 235
  • Dynamic IDs can range from 0 to 4096 when using category ID 0
  • When using other category IDs, dynamic IDs are limited to a 0 to 235 range instead

The following component types are available:

Interfaces

An interface represents a collection of static components, along with some additional information used for tracking their state. They're mainly an engine concept, and plugins simply use them as containers for their components.

See here for additional information on interfaces.

Style Sheets

Style sheets

See here for additional information on style sheets as well as suggestions for what styles to use.