Zelda HLE: Skip command words that are not commands.

Zelda Twilight Princess (GC) seems to push null words into the command buffer.
The command handler in the UCode ignores initial command mails that do not have
the MSB set.
This commit is contained in:
Pierre Bourdon 2014-12-21 06:20:28 +01:00
parent 9944731516
commit b672788548
1 changed files with 5 additions and 2 deletions

View File

@ -173,13 +173,16 @@ void ZeldaUCode::RunPendingCommands()
while (m_pending_commands_count)
{
m_pending_commands_count--;
u32 cmd_mail = Read32();
if (!(cmd_mail & 0x80000000))
continue;
u32 command = (cmd_mail >> 24) & 0x7f;
u32 sync = cmd_mail >> 16;
u32 extra_data = cmd_mail & 0xFFFF;
m_pending_commands_count--;
switch (command)
{
case 0x00: