Skip to content

Return of Reckoning

Wiki

RoR Wiki

API:IsPlayerMainAssist

From RoR Wiki
Revision as of 19:45, 16 October 2026 by Maintenance script (talk | contribs) (UI Lua API import (WAR 1.4.8))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

UI Lua API · Group functions
Version: WAR 1.4.8

Returns whether the player is the main assist of their group, as the number 1 or 0.

isMainAssist = IsPlayerMainAssist()

Arguments

None.

Returns

isMainAssist
number – 1 if the main assist id the client has stored equals the player's own character id, otherwise 0. Nothing if there is no player object.

Details

  • The result is a number, not a boolean. 0 is a true value in Lua, so compare with == 1, as the stock UI does.
  • The same stored main assist id is used for the isMainAssist field of GameData.GetScenarioPlayerGroups.

Errors

None.

Example

From default/ea_playerstatuswindow/source/playerwindow.lua:

playerIsMainAssist = ( IsPlayerMainAssist() == 1 )

See also