Skip to content
Rift
Search
Ctrl
K
Cancel
Discord
Select theme
Dark
Light
Auto
Rift
The Rift ECS
Gameplay hooks
Lifecycle hooks
Save files and persistence
Hooks
on_all_modals_closed
on_body_possessed
Advanced
on_body_released
Advanced
on_client_body_created
Advanced
on_command
on_component_option
on_create
on_enter_area
on_event
Advanced
on_hour
on_idle_logout_due
on_input
Advanced
on_inventory_option
on_leave_area
on_level_up
on_load
on_logging_out
on_login
on_logout_requested
on_minimap_click
on_modal_opened
on_music_ended
on_new_account
on_npc_option
on_object_option
on_participant_released
on_phase
on_place_recovered
on_player_option
on_public_chat
on_realm_stop
on_self_despawn
on_self_entered
on_self_event
on_self_hit
on_self_item_used
on_self_left
on_self_option
on_self_participant_released
on_self_spawn
on_sequence
on_sequence_end
on_ui_component_click
on_ui_component_drag
on_ui_continue
on_ui_item_submit
on_ui_name_submit
on_ui_number_submit
on_ui_text_submit
on_world_click
on_world_item_option
on_world_start
on_xp_gain
Declarations
day_cycle
define_area
engine_config
game_loop
node
self
sequence
Rift: API Reference
Overview
rift.assets
Overview
rift.chat
Overview
rift.components
Overview
rift.entities
Overview
rift.inputs
Overview
rift.items
Overview
rift.moderation
Overview
rift.scripting
Overview
rift.ui
Overview
rift.util
Overview
rift.world
Overview
rift.cmd.cli
Advanced
Overview
rift.config
Advanced
Overview
AnimationCycles
Advanced
ConfigColumn
Advanced
ConfigDatabase
Advanced
ConfigDatabaseResult
Advanced
ConfigNames
Advanced
ConfigRecord
Advanced
ConfigRefusal
Advanced
ConfigRowNode
Advanced
ConfigTable
Advanced
ConfigTableRecordFields
Advanced
ConfigTables
Advanced
ConfigType
Advanced
ConfigTypeBool
Advanced
ConfigTypeIntType
Advanced
ConfigTypeListOf
Advanced
ConfigTypeMapOf
Advanced
ConfigTypeOther
Advanced
ConfigTypeRecord
Advanced
ConfigTypeText
Advanced
DefinitionService
Advanced
Inventories
Advanced
Items
Advanced
Jingles
Advanced
Music
Advanced
Npcs
Advanced
Overheads
Advanced
ServerTables
Advanced
Sounds
Advanced
WorldObjects
Advanced
rift.ecs
Advanced
Overview
rift.packages
Advanced
Overview
rift.packets
Advanced
Overview
rift.sequences
Advanced
Overview
rift.social
Advanced
Overview
Scripting: Riftlang
Getting started with Riftlang
Guides
Riftlang for JS/TS programmers
Riftlang for Java programmers
Riftlang for Kotlin programmers
Riftlang tooling in 5 minutes
Language reference
Basic syntax
Types
Control flow
Null safety
Functions and lambdas
Classes and objects
Packages and imports
Keyword reference
UI: ts2
Getting started with ts2
Quick start
Essentials
Writing markup
Your first component
Passing props
Conditional rendering
Rendering lists
Layout and geometry
Data
Composing components
Responding to events
Referencing components with refs
Hover and menus
Keyboard, input and drag
Game state
Interface state
Watching and reacting
Timers
How updates happen
Talking to the game
Interfaces and slots
Server entry points
Engine hooks
Writing it well
Reference
Overview
Elements
Common props
<layer>
<rect>
<text>
<sprite>
<model>
<line>
<input>
<ui>
Hooks
Hooks
useServerState
useSkill
useSkillBase
useInventory
predictServerState
useState
sessionState
persistedState
useRef
createRef
useInterval
useDelay
stopTimer
onMounted
onUpdated
useWatch
useRerenderOn
useOnResize
useUniverse
Engine
useDerived
useServerStateOnce
resumePauseButton
param
defineEngineHooks
intArray
Event
Types
Collections
Globals
Standard library
Supported syntax
ts2.config.json
The ts2 command
Build outputs
Diagnostics
Rules of ts2
Extra topics
How updates reach the screen
Three kinds of list
Coming from a component framework
Learn
ECS Fundamentals
Discord
Select theme
Dark
Light
Auto
AnimationCycles
Advanced
object
AnimationCycles
of
Section titled โofโ
Advanced
fun
of
(animation: Int): Int?