<?xml version="1.0" encoding="utf-8"?>
<CheatTable CheatEngineTableVersion="50">
  <CheatEntries>
    <CheatEntry>
      <ID>13</ID>
      <Description>"Force Allow Character Swaps"</Description>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>[ENABLE]
{$lua}
if syntaxcheck then return end
if not script then script = {} end
local regName = "charSwapAvailableValues"
unregisterSymbol(regName)
autoAssemble([[
aobscanmodule(]]..regName..[[,$process,F6 * * 0F 85 * * * * 8B * * C6 * * * 66 * * * * * E9)
registersymbol(]]..regName..[[)
]])
local addr = getAddressSafe(regName)+0xC
unregisterSymbol(regName)
script[regName] = {}
local tbl = script[regName]
tbl.Value1 = readByte(addr+0x3)
tbl.Value2 = readSmallInteger(addr+0x8)
regName = "Force_Allow_Character_Swaps"
unregisterSymbol(regName)
autoAssemble([[
aobscanmodule(]]..regName..[[,$process,E9 * * * * 8B * * C6 * * * 66 * * * * * 8B)
registersymbol(]]..regName..[[)
]])
addr = getAddressSafe(regName)
tbl.OrigJmpBytes = readBytes(addr, 0x5, true)
addr = addr+0x8
tbl.OrigValue1 = readByte(addr+0x3)
tbl.OrigValue2 = readSmallInteger(addr+0x8)

addr = getAddressSafe(regName)
writeBytes(addr, {0x90, 0x90, 0x90, 0x90, 0x90})
writeByte(addr+0xB, tbl.Value1)
writeSmallInteger(addr+0x10, tbl.Value2)
{$asm}
[DISABLE]
{$lua}
if syntaxcheck then return end
local regName = "Force_Allow_Character_Swaps"
addr = getAddressSafe(regName)
writeBytes(addr, script.charSwapAvailableValues.OrigJmpBytes)
writeByte(addr+0xB, script.charSwapAvailableValues.OrigValue1)
writeSmallInteger(addr+0x10, script.charSwapAvailableValues.OrigValue2)
unregisterSymbol(regName)
if script then
    script.charSwapAvailableValues = nil
end
{$asm}
</AssemblerScript>
    </CheatEntry>
    <CheatEntry>
      <ID>14</ID>
      <Description>"Zero: Force Saber Attack"</Description>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>[ENABLE]
{$lua}
if syntaxcheck then return end
local regName = "Zero_Force_Saber_Attack"
local aob = "F6 * * 0F 84 * * * * 8B * * 33 * 8A * * * * * * * 0F 84"
unregisterSymbol(regName)
autoAssemble([[
aobscanmodule(]]..regName..[[,$process,]]..aob..[[)
registersymbol(]]..regName..[[)
]])
local startAddr = getAddressSafe(regName)+aob:len()
local endAddr = startAddr+getModuleSize(process)
unregisterSymbol(regName)
autoAssemble([[
aobscanregion(]]..regName..[[,]]..string.format("%08X", startAddr)..[[,]]..string.format("%08X", endAddr)..[[,]]..aob..[[)
registersymbol(]]..regName..[[)
]])
{$asm}

Zero_Force_Saber_Attack+17:
  db 80

[DISABLE]

Zero_Force_Saber_Attack+17:
  db 84

unregistersymbol(Zero_Force_Saber_Attack)
</AssemblerScript>
    </CheatEntry>
    <CheatEntry>
      <ID>6</ID>
      <Description>"Game Data"</Description>
      <Options moHideChildren="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{$lua}
if syntaxcheck then return end
[ENABLE]
if not GameData then GameData = {} end
local regName = "tmpSym"
unregisterSymbol(regName)
autoAssemble([[
aobscanmodule(]]..regName..[[,$process,A1 * * * * 66 * * * 8B * * * * * 66)
registersymbol(]]..regName..[[)
]])
local addr = getAddressSafe(regName)
unregisterSymbol(regName)
GameData.Address = readInteger(addr+0x1)
[DISABLE]
GameData = nil
{$asm}
</AssemblerScript>
      <CheatEntries>
        <CheatEntry>
          <ID>8</ID>
          <Description>"Game Data"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <GroupHeader>1</GroupHeader>
          <Address>GameData.Address</Address>
          <Offsets>
            <Offset>0</Offset>
          </Offsets>
          <CheatEntries>
            <CheatEntry>
              <ID>10</ID>
              <Description>"Communication Monitor Disabled"</Description>
              <DropDownList ReadOnly="1" DescriptionOnly="1" DisplayValueAsItem="1">0:Unset
1:Set
</DropDownList>
              <ShowAsSigned>0</ShowAsSigned>
              <VariableType>Binary</VariableType>
              <BitStart>7</BitStart>
              <BitLength>1</BitLength>
              <ShowAsBinary>0</ShowAsBinary>
              <Address>+107</Address>
            </CheatEntry>
            <CheatEntry>
              <ID>11</ID>
              <Description>"Zero is Dead"</Description>
              <DropDownList ReadOnly="1" DescriptionOnly="1" DisplayValueAsItem="1">0:Unset
1:Set
</DropDownList>
              <ShowAsSigned>0</ShowAsSigned>
              <VariableType>Binary</VariableType>
              <BitStart>6</BitStart>
              <BitLength>1</BitLength>
              <ShowAsBinary>0</ShowAsBinary>
              <Address>+12D</Address>
            </CheatEntry>
            <CheatEntry>
              <ID>5</ID>
              <Description>"Has Swapped to Zero"</Description>
              <DropDownList ReadOnly="1" DescriptionOnly="1" DisplayValueAsItem="1">0:Unset
1:Set
</DropDownList>
              <ShowAsSigned>0</ShowAsSigned>
              <VariableType>Binary</VariableType>
              <BitStart>0</BitStart>
              <BitLength>1</BitLength>
              <ShowAsBinary>0</ShowAsBinary>
              <Address>+15C</Address>
            </CheatEntry>
          </CheatEntries>
        </CheatEntry>
      </CheatEntries>
    </CheatEntry>
  </CheatEntries>
  <UserdefinedSymbols/>
</CheatTable>
