Sly 1:Executable: Difference between revisions
Jump to navigation
Jump to search
Content added Content deleted
TheOnlyZac (talk | contribs) (→Initialization and main loop: Fixed typos, tweaked wording) Tags: Mobile edit Mobile web edit |
TheOnlyZac (talk | contribs) m (→Initialization and main loop: Minor text fixes) |
||
Line 37:
* First, check if <code>g_mpeg</code> has an [[MPEG]] queued to be played. If so:
** <code>FlushFrames(1)
** <code>CTransition::Execute(&g_transition)
* Check if <code>g_transition</code> has a pending transition (<code>m_fPending != 0</code>). If so:
** <code>FlushFrames(1)
** Call a function that calls <code>CMpeg::Execute</code> on the <code>g_transition</code> instance
* Check '''again''' if <code>g_mpeg</code> has an MPEG queued to be played (this happens if two MPEGs were queued to play back-to-back) If so:
** <code>FlushFrames(1)
** <code>CTransition::Execute(&g_transition)
* <code>UpdateJoy(&g_joy)
* <code>UpdateCodes()
* <code>unk_save_related(&g_save_related_as4)
* <code>UpdateUi(&g_ui)
* <code>UpdateGameState(g_clock.dt)
* <code>if (g_psw != (SW *)0x0)</code> – If g_psw is not NULL...
** <code>SetupCm(g_pcm)
** <code>OpenFrame()
** <code>MarkClockTick(&g_clock)
** Grab a function pointer from the <code>g_psw</code> struct and execute it if it is not NULL (the function takes <code>g_clock.dt</code> as an argument)
** <code>RenderSw(g_psw,g_pcm)
** <code>RenderUi()
** <code>DrawSw(g_psw,g_pcm)
** <code>DrawUi()
** <code>CloseFrame()
* <code>g_cframe
This loop continues infinitely unless <code>Exit</code> is called or a handled exception causes execution to halt, in which case you are immediately booted back to the PS2 BIOS.
|