Skip to content

Return of Reckoning

Wiki

RoR Wiki

API:OpenURL

From RoR Wiki
Revision as of 19:47, 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 · Interface functions
Version: WAR 1.4.8

Opens one of the client's predefined web addresses in the default web browser.

OpenURL(urlIndex)

Arguments

urlIndex
number – Index of the address in the client's URL list. Use the GameData.URLs values. Fractions are dropped.

Returns

Nothing.

Details

  • The address is not passed from Lua: the index is looked up in the client's built-in URLs data list. An addon cannot open an arbitrary address with this function.
  • An index outside the list gives an empty address, and nothing is opened.
  • An address without a scheme gets http added. An address with a scheme is opened only if the scheme is http or https (case does not matter); anything else is not opened.
  • The address is opened through the Windows shell with the "open" verb, which normally starts the default browser.
  • No result is returned to Lua, so a script cannot tell whether a browser was started.
  • The function needs at least one argument and only reads the last one.

Errors

None besides the generic Invalid Parameters message when the argument is missing or not a number.

Example

From ea_helpwindow/source/faqwindow.lua:

OpenURL( GameData.URLs.URL_KNOWLEDGE_BASE )

From interfacecore/source/transferpopupwindow.lua:

OpenURL( GameData.URLs.URL_ACCOUNT_MANAGEMENT )

See also