Skip to content

Return of Reckoning

Wiki

RoR Wiki

API:PregamePlayCinematic

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 · Pregame functions
Version: WAR 1.4.8

Starts playing the intro cinematic on the pregame screens.

PregamePlayCinematic()

Arguments

None.

Returns

Nothing.

Details

  • The call only works in the pregame state while the character select screen is set up. At any other time it does nothing.
  • It also does nothing unless the conditions of CanPlayCinematic are met: the video file videos/Cinematic1_720p.bik must exist in the game archives, and the sound system, if it exists, must be ready for video.
  • The video is played into the texture named title_screen_video. The stock window EA_Window_CinematicDisplay (interfacecore/source/cinematicwindow.xml) shows that texture in a DynamicImage, so a window like it must be shown for the video to be visible.
  • While the video plays, the client stops the pregame theme music and sets the same flag as PregameBlockMouseOver(true). The previous value of the flag is remembered.
  • If the video cannot be opened, nothing is played.
  • Use PregameStopCinematic to end playback.

Errors

None.

Example

From interfacecore/source/cinematicwindow.lua:

function EA_Window_CinematicDisplay.Show()
    if ( CanPlayCinematic() )
    then
        if ( DoesWindowExist( "EA_Window_CinematicDisplay" ) )
        then
            WindowSetShowing("EA_Window_CinematicDisplay", true)
        else
            CreateWindow("EA_Window_CinematicDisplay", true)
        end
        PregamePlayCinematic()
    else
        -- offer to open the cinematic web page instead
    end
end

See also