<?xml version="1.0" encoding="utf-8"?>
<CheatTable CheatEngineTableVersion="45">
  <CheatEntries>
    <CheatEntry>
      <ID>4</ID>
      <Description>"inf. item/ability pt use (count must &gt;1)"</Description>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-18
  Author : bbfox@https://opencheattables.com
}

[ENABLE]

aobscanmodule(INJECT_INF_ITEM,$process,85 DB 79 07 8B 58 04) // should be unique
alloc(newmem,$1000,INJECT_INF_ITEM)

label(code)
label(return)

newmem:
  cmp ebx, 0
  jl code

  cmp dword ptr [rax+04], 1
  je code

  cmp dword ptr [rax], 3 // ability pt
  jne chk_coco

  cmp dword ptr [rax+04], #3000
  jae normal_set2

  mov dword ptr [rax+04], #3000
  jmp normal_set2

chk_coco:
  cmp dword ptr [rax], 1 // Gil
  jne normal_set

  cmp dword ptr [rax+04], #10000
  jae normal_set2

  mov dword ptr [rax+04], #10000
  jmp normal_set2

normal_set:
  cmp dword ptr [rax+04], 3E7
  jbe @F
  cmp dword ptr [rax+04], 1388
  jae @F
  mov dword ptr [rax+04], 1388
  jmp normal_set2

@@:
  cmp dword ptr [rax+04], 63
  jbe @F
  mov dword ptr [rax+04], 3E7
  jmp normal_set2

@@:
  cmp dword ptr [rax+04], A
  jbe @F
  mov dword ptr [rax+04], 63
  jmp normal_set2

@@:

normal_set2:
  xor ebx, ebx


code:
  test ebx,ebx
  jns ffxvi.exe+6A8FE2
  mov ebx,[rax+04]
  jmp return

INJECT_INF_ITEM:
  jmp newmem
  nop 2
return:
registersymbol(INJECT_INF_ITEM)

[DISABLE]

INJECT_INF_ITEM:
  db 85 DB 79 07 8B 58 04

unregistersymbol(INJECT_INF_ITEM)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+6A8FD7

ffxvi.exe+6A8FBC: 48 85 D2              - test rdx,rdx
ffxvi.exe+6A8FBF: 74 2E                 - je ffxvi.exe+6A8FEF
ffxvi.exe+6A8FC1: 48 83 C0 08           - add rax,08
ffxvi.exe+6A8FC5: 39 38                 - cmp [rax],edi
ffxvi.exe+6A8FC7: 74 0E                 - je ffxvi.exe+6A8FD7
ffxvi.exe+6A8FC9: 48 FF C1              - inc rcx
ffxvi.exe+6A8FCC: 48 83 C0 10           - add rax,10
ffxvi.exe+6A8FD0: 48 3B CA              - cmp rcx,rdx
ffxvi.exe+6A8FD3: 72 F0                 - jb ffxvi.exe+6A8FC5
ffxvi.exe+6A8FD5: EB 18                 - jmp ffxvi.exe+6A8FEF
// ---------- INJECTING HERE ----------
ffxvi.exe+6A8FD7: 85 DB                 - test ebx,ebx
// ---------- DONE INJECTING  ----------
ffxvi.exe+6A8FD9: 79 07                 - jns ffxvi.exe+6A8FE2
ffxvi.exe+6A8FDB: 8B 58 04              - mov ebx,[rax+04]
ffxvi.exe+6A8FDE: 8B CB                 - mov ecx,ebx
ffxvi.exe+6A8FE0: EB 03                 - jmp ffxvi.exe+6A8FE5
ffxvi.exe+6A8FE2: 8B 48 04              - mov ecx,[rax+04]
ffxvi.exe+6A8FE5: 2B CB                 - sub ecx,ebx
ffxvi.exe+6A8FE7: 85 C9                 - test ecx,ecx
ffxvi.exe+6A8FE9: 0F 4E CE              - cmovle ecx,esi
ffxvi.exe+6A8FEC: 89 48 04              - mov [rax+04],ecx
ffxvi.exe+6A8FEF: 48 8B 0D EA EF 16 01  - mov rcx,[ffxvi.exe+1817FE0]
}
</AssemblerScript>
    </CheatEntry>
    <CheatEntry>
      <ID>5</ID>
      <Description>"Menu -&gt; item set item count (item count must &gt;1)"</Description>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-18
  Author :
}

[ENABLE]

aobscanmodule(INJECT_FILL_ITEM,ffxvi.exe,8B 4C C8 0C 33 C0) // should be unique
alloc(newmem,$1000,INJECT_FILL_ITEM)

label(code)
label(return)

newmem:
  cmp dword ptr [rax+rcx*8+08], 3
  jbe code

  cmp dword ptr [rax+rcx*8+0C], 2
  jb code

  cmp dword ptr [rax+rcx*8+0C], 9
  ja @F

  mov dword ptr [rax+rcx*8+0C], 9
  jmp code

@@:
  cmp dword ptr [rax+rcx*8+0C], 63
  ja @F

  mov dword ptr [rax+rcx*8+0C], 63
  jmp code

@@:
  cmp dword ptr [rax+rcx*8+0C], 3E7
  ja @F

  mov dword ptr [rax+rcx*8+0C], 3E7
  jmp code

@@:
  cmp dword ptr [rax+rcx*8+0C], 1388
  ja @F

  mov dword ptr [rax+rcx*8+0C], 1388
  jmp code

code:
  mov ecx,[rax+rcx*8+0C]
  xor eax,eax
  jmp return

INJECT_FILL_ITEM:
  jmp newmem
  nop
return:
registersymbol(INJECT_FILL_ITEM)

[DISABLE]

INJECT_FILL_ITEM:
  db 8B 4C C8 0C 33 C0

unregistersymbol(INJECT_FILL_ITEM)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+298D20

ffxvi.exe+298CF9: 8B D6              - mov edx,esi
ffxvi.exe+298CFB: E8 CC 00 41 00     - call ffxvi.exe+6A8DCC
ffxvi.exe+298D00: 48 89 45 E0        - mov [rbp-20],rax
ffxvi.exe+298D04: 41 BC FF FF FF FF  - mov r12d,FFFFFFFF
ffxvi.exe+298D0A: 44 8B 38           - mov r15d,[rax]
ffxvi.exe+298D0D: E9 A6 01 00 00     - jmp ffxvi.exe+298EB8
ffxvi.exe+298D12: 41 8B CF           - mov ecx,r15d
ffxvi.exe+298D15: 48 03 C9           - add rcx,rcx
ffxvi.exe+298D18: C6 45 C0 00        - mov byte ptr [rbp-40],00
ffxvi.exe+298D1C: 8B 5C C8 08        - mov ebx,[rax+rcx*8+08]
// ---------- INJECTING HERE ----------
ffxvi.exe+298D20: 8B 4C C8 0C        - mov ecx,[rax+rcx*8+0C]
// ---------- DONE INJECTING  ----------
ffxvi.exe+298D24: 33 C0              - xor eax,eax
ffxvi.exe+298D26: 3B 5C 85 E8        - cmp ebx,[rbp+rax*4-18]
ffxvi.exe+298D2A: 75 0B              - jne ffxvi.exe+298D37
ffxvi.exe+298D2C: FF C1              - inc ecx
ffxvi.exe+298D2E: C6 45 C0 01        - mov byte ptr [rbp-40],01
ffxvi.exe+298D32: 83 64 85 E8 00     - and dword ptr [rbp+rax*4-18],00
ffxvi.exe+298D37: 48 FF C0           - inc rax
ffxvi.exe+298D3A: 48 83 F8 03        - cmp rax,03
ffxvi.exe+298D3E: 7C E6              - jl ffxvi.exe+298D26
ffxvi.exe+298D40: 89 4D C8           - mov [rbp-38],ecx
}
</AssemblerScript>
    </CheatEntry>
    <CheatEntry>
      <ID>23</ID>
      <Description>"Limit break multiplier"</Description>
      <Options moHideChildren="1"/>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-19
  Author : bbfox@https://opencheattables.com
}

[ENABLE]

aobscanmodule(INJECT_LIMIT_BREAK_MULTI,$process,44 01 4B 48 48 8B CB) // should be unique
alloc(newmem,$1000,INJECT_LIMIT_BREAK_MULTI)

label(code)
label(return)
label(vf_lb_multi)
label(i_min_lb_value)

newmem:
  cmp r9d, 0
  jle code

  push r15
  mov r15d, [i_min_lb_value]
  cmp dword ptr [rbx+48], r15d
  jae @F

  mov dword ptr [rbx+48], r15d
@@:
  pop r15

  vcvtsi2ss xmm15, xmm15, r9d
  vmovss xmm14, [vf_lb_multi]
  vmulss xmm15, xmm14, xmm15
  vcvtss2si r9d, xmm15

code:
  add [rbx+48],r9d
  mov rcx,rbx
  jmp return
align 10 cc
  vf_lb_multi:
  dd (float)3.3333333333
  i_min_lb_value:
  dd #10000

INJECT_LIMIT_BREAK_MULTI:
  jmp newmem
  nop 2
return:
registersymbol(INJECT_LIMIT_BREAK_MULTI)
registersymbol(vf_lb_multi)
registersymbol(i_min_lb_value)
[DISABLE]

INJECT_LIMIT_BREAK_MULTI:
  db 44 01 4B 48 48 8B CB

unregistersymbol(*)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+5DDBEF

ffxvi.exe+5DDBD6: 45 84 C0        - test r8b,r8b
ffxvi.exe+5DDBD9: 74 14           - je ffxvi.exe+5DDBEF
ffxvi.exe+5DDBDB: 8B 4B 18        - mov ecx,[rbx+18]
ffxvi.exe+5DDBDE: 8B C1           - mov eax,ecx
ffxvi.exe+5DDBE0: C1 E8 02        - shr eax,02
ffxvi.exe+5DDBE3: A8 01           - test al,01
ffxvi.exe+5DDBE5: 74 08           - je ffxvi.exe+5DDBEF
ffxvi.exe+5DDBE7: C1 E9 0A        - shr ecx,0A
ffxvi.exe+5DDBEA: F6 C1 01        - test cl,01
ffxvi.exe+5DDBED: 74 1C           - je ffxvi.exe+5DDC0B
// ---------- INJECTING HERE ----------
ffxvi.exe+5DDBEF: 44 01 4B 48     - add [rbx+48],r9d
// ---------- DONE INJECTING  ----------
ffxvi.exe+5DDBF3: 48 8B CB        - mov rcx,rbx
ffxvi.exe+5DDBF6: E8 59 FF FF FF  - call ffxvi.exe+5DDB54
ffxvi.exe+5DDBFB: 39 43 48        - cmp [rbx+48],eax
ffxvi.exe+5DDBFE: 7E 0B           - jle ffxvi.exe+5DDC0B
ffxvi.exe+5DDC00: 48 8B CB        - mov rcx,rbx
ffxvi.exe+5DDC03: E8 4C FF FF FF  - call ffxvi.exe+5DDB54
ffxvi.exe+5DDC08: 89 43 48        - mov [rbx+48],eax
ffxvi.exe+5DDC0B: 48 83 C4 20     - add rsp,20
ffxvi.exe+5DDC0F: 5B              - pop rbx
ffxvi.exe+5DDC10: C3              - ret 
}
</AssemblerScript>
      <CheatEntries>
        <CheatEntry>
          <ID>24</ID>
          <Description>"Multiplier"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>C08000</Color>
          <VariableType>Float</VariableType>
          <Address>vf_lb_multi</Address>
        </CheatEntry>
        <CheatEntry>
          <ID>25</ID>
          <Description>"min. value"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>C08000</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_min_lb_value</Address>
        </CheatEntry>
      </CheatEntries>
    </CheatEntry>
    <CheatEntry>
      <ID>10</ID>
      <Description>"Get HP"</Description>
      <Options moHideChildren="1" moDeactivateChildrenAsWell="1"/>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-18
  Author : bbfox@https://opencheattables.com
}

[ENABLE]

aobscanmodule(INJECT_GET_HP,$process,8B 47 40 89 43 20) // should be unique
alloc(newmem,$1000,INJECT_GET_HP)

label(code)
label(return)
label(i_base_hp_addr)
label(is_reset_hp_addr)

newmem:
  mov [i_base_hp_addr], rdi

code:
  mov eax,[rdi+40]
  mov [rbx+20],eax
  jmp return
align 10 cc
  i_base_hp_addr:
  dq 0
  is_reset_hp_addr:
  dd 0

INJECT_GET_HP:
  jmp newmem
  nop
return:
registersymbol(is_reset_hp_addr)
registersymbol(INJECT_GET_HP)
registersymbol(i_base_hp_addr)
[DISABLE]

INJECT_GET_HP:
  db 8B 47 40 89 43 20

unregistersymbol(*)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+21E8A3

ffxvi.exe+21E886: 89 73 18        - mov [rbx+18],esi
ffxvi.exe+21E889: 8B 4B 14        - mov ecx,[rbx+14]
ffxvi.exe+21E88C: F6 C1 01        - test cl,01
ffxvi.exe+21E88F: 75 0D           - jne ffxvi.exe+21E89E
ffxvi.exe+21E891: 48 8B 40 10     - mov rax,[rax+10]
ffxvi.exe+21E895: 8B 48 0C        - mov ecx,[rax+0C]
ffxvi.exe+21E898: 89 4B 1C        - mov [rbx+1C],ecx
ffxvi.exe+21E89B: 8B 4B 14        - mov ecx,[rbx+14]
ffxvi.exe+21E89E: F6 C1 02        - test cl,02
ffxvi.exe+21E8A1: 75 06           - jne ffxvi.exe+21E8A9
// ---------- INJECTING HERE ----------
ffxvi.exe+21E8A3: 8B 47 40        - mov eax,[rdi+40]
// ---------- DONE INJECTING  ----------
ffxvi.exe+21E8A6: 89 43 20        - mov [rbx+20],eax
ffxvi.exe+21E8A9: 48 8B CF        - mov rcx,rdi
ffxvi.exe+21E8AC: E8 8F EE 3B 00  - call ffxvi.exe+5DD740
ffxvi.exe+21E8B1: 89 43 24        - mov [rbx+24],eax
ffxvi.exe+21E8B4: 48 8B CF        - mov rcx,rdi
ffxvi.exe+21E8B7: 8B 47 50        - mov eax,[rdi+50]
ffxvi.exe+21E8BA: 89 43 28        - mov [rbx+28],eax
ffxvi.exe+21E8BD: 8B 47 48        - mov eax,[rdi+48]
ffxvi.exe+21E8C0: 89 43 2C        - mov [rbx+2C],eax
ffxvi.exe+21E8C3: E8 8C F2 3B 00  - call ffxvi.exe+5DDB54
}
</AssemblerScript>
      <CheatEntries>
        <CheatEntry>
          <ID>12</ID>
          <Description>"Usage: enable in status window"</Description>
          <Color>8000FF</Color>
          <GroupHeader>1</GroupHeader>
        </CheatEntry>
        <CheatEntry>
          <ID>11</ID>
          <Description>"HP"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>FF8080</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_base_hp_addr</Address>
          <Offsets>
            <Offset>40</Offset>
          </Offsets>
        </CheatEntry>
        <CheatEntry>
          <ID>22</ID>
          <Description>"Limit Break"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>FF8080</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_base_hp_addr</Address>
          <Offsets>
            <Offset>48</Offset>
          </Offsets>
        </CheatEntry>
        <CheatEntry>
          <ID>16</ID>
          <Description>"faster kill"</Description>
          <VariableType>Auto Assembler Script</VariableType>
          <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-18
  Author : bbfox@https://opencheattables.com
}

[ENABLE]

aobscanmodule(INJECT_1HK,$process,2B 4B 40 49 8B D7) // should be unique
alloc(newmem,$1000,INJECT_1HK)

label(code)
label(return)

newmem:
  cmp rbx, [i_base_hp_addr]
  je code

  cmp dword ptr [rbx+40], 1
  jbe code
  mov dword ptr [rbx+40], 1

code:
  sub ecx,[rbx+40]
  mov rdx,r15
  jmp return

INJECT_1HK:
  jmp newmem
  nop
return:
registersymbol(INJECT_1HK)

[DISABLE]

INJECT_1HK:
  db 2B 4B 40 49 8B D7

unregistersymbol(INJECT_1HK)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+591488

ffxvi.exe+59145E: 74 0E                 - je ffxvi.exe+59146E
ffxvi.exe+591460: 48 8B 05 41 69 28 01  - mov rax,[ffxvi.exe+1817DA8]
ffxvi.exe+591467: C7 40 4C E7 8C 88 3E  - mov [rax+4C],3E888CE7
ffxvi.exe+59146E: 8B 4D 88              - mov ecx,[rbp-78]
ffxvi.exe+591471: 85 C9                 - test ecx,ecx
ffxvi.exe+591473: 0F 8E DC 00 00 00     - jng ffxvi.exe+591555
ffxvi.exe+591479: 41 8B 87 C4 00 00 00  - mov eax,[r15+000000C4]
ffxvi.exe+591480: C1 E8 02              - shr eax,02
ffxvi.exe+591483: 40 84 C6              - test sil,al
ffxvi.exe+591486: 74 6D                 - je ffxvi.exe+5914F5
// ---------- INJECTING HERE ----------
ffxvi.exe+591488: 2B 4B 40              - sub ecx,[rbx+40]
// ---------- DONE INJECTING  ----------
ffxvi.exe+59148B: 49 8B D7              - mov rdx,r15
ffxvi.exe+59148E: 41 8B 87 94 01 00 00  - mov eax,[r15+00000194]
ffxvi.exe+591495: 44 8B C9              - mov r9d,ecx
ffxvi.exe+591498: 45 8B 87 74 01 00 00  - mov r8d,[r15+00000174]
ffxvi.exe+59149F: 48 8B 0D E2 68 28 01  - mov rcx,[ffxvi.exe+1817D88]
ffxvi.exe+5914A6: C1 E8 15              - shr eax,15
ffxvi.exe+5914A9: 40 22 C6              - and al,sil
ffxvi.exe+5914AC: 88 44 24 20           - mov [rsp+20],al
ffxvi.exe+5914B0: E8 DB 5D CC FF        - call ffxvi.exe+257290
ffxvi.exe+5914B5: 48 8B 0D 4C 68 28 01  - mov rcx,[ffxvi.exe+1817D08]
}
</AssemblerScript>
        </CheatEntry>
      </CheatEntries>
    </CheatEntry>
    <CheatEntry>
      <ID>13</ID>
      <Description>"Get Gil/AP"</Description>
      <Options moHideChildren="1"/>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-18
  Author : bbfox@https://opencheattables.com
}

[ENABLE]

aobscanmodule(INJECT_GET_GIL_AP,$process,8B 42 04 EB F0) // should be unique
alloc(newmem,$1000,INJECT_GET_GIL_AP)

label(code)
label(return)
label(i_base_ap_addr)
label(i_base_gil_addr)
label(i_base_id2_addr)

newmem:
  cmp dword ptr [rdx], 1
  jne @F
  mov [i_base_gil_addr], rdx
  jmp code
@@:

  cmp dword ptr [rdx], 2
  jne @F
  mov [i_base_id2_addr], rdx
  jmp code
@@:

  cmp dword ptr [rdx], 3
  jne @F
  mov [i_base_ap_addr], rdx
  jmp code
@@:

code:
  mov eax,[rdx+04]
  reassemble(INJECT_GET_GIL_AP+3)
  //jmp ffxvi.exe+6A96CA
  jmp return
align 10 cc
  i_base_ap_addr:
  dq 0
  i_base_gil_addr:
  dq 0
  i_base_id2_addr:
  dq 0

INJECT_GET_GIL_AP:
  jmp newmem
return:
registersymbol(INJECT_GET_GIL_AP)
registersymbol(i_base_ap_addr)
registersymbol(i_base_gil_addr)
registersymbol(i_base_id2_addr)
[DISABLE]

INJECT_GET_GIL_AP:
  db 8B 42 04 EB F0

unregistersymbol(*)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+6A96D5

ffxvi.exe+6A96BB: 39 3A           - cmp [rdx],edi
ffxvi.exe+6A96BD: 74 16           - je ffxvi.exe+6A96D5
ffxvi.exe+6A96BF: 48 83 C2 10     - add rdx,10
ffxvi.exe+6A96C3: 49 3B D0        - cmp rdx,r8
ffxvi.exe+6A96C6: 75 F3           - jne ffxvi.exe+6A96BB
ffxvi.exe+6A96C8: 33 C0           - xor eax,eax
ffxvi.exe+6A96CA: 48 8B 5C 24 30  - mov rbx,[rsp+30]
ffxvi.exe+6A96CF: 48 83 C4 20     - add rsp,20
ffxvi.exe+6A96D3: 5F              - pop rdi
ffxvi.exe+6A96D4: C3              - ret 
// ---------- INJECTING HERE ----------
ffxvi.exe+6A96D5: 8B 42 04        - mov eax,[rdx+04]
// ---------- DONE INJECTING  ----------
ffxvi.exe+6A96D8: EB F0           - jmp ffxvi.exe+6A96CA
ffxvi.exe+6A96DA: CC              - int 3 
ffxvi.exe+6A96DB: CC              - int 3 
ffxvi.exe+6A96DC: 48 89 5C 24 08  - mov [rsp+08],rbx
ffxvi.exe+6A96E1: 57              - push rdi
ffxvi.exe+6A96E2: 48 83 EC 30     - sub rsp,30
ffxvi.exe+6A96E6: 41 8B D8        - mov ebx,r8d
ffxvi.exe+6A96E9: 8B FA           - mov edi,edx
ffxvi.exe+6A96EB: E8 10 F7 FF FF  - call ffxvi.exe+6A8E00
ffxvi.exe+6A96F0: 4C 8B C8        - mov r9,rax
}
</AssemblerScript>
      <CheatEntries>
        <CheatEntry>
          <ID>14</ID>
          <Description>"Gil"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>FF8080</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_base_gil_addr</Address>
          <Offsets>
            <Offset>4</Offset>
          </Offsets>
        </CheatEntry>
        <CheatEntry>
          <ID>15</ID>
          <Description>"AP"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>FF8080</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_base_ap_addr</Address>
          <Offsets>
            <Offset>4</Offset>
          </Offsets>
        </CheatEntry>
      </CheatEntries>
    </CheatEntry>
    <CheatEntry>
      <ID>17</ID>
      <Description>"Gil gain: *4 income"</Description>
      <Options moHideChildren="1"/>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-18
  Author : bbfox@https://opencheattables.com
}

[ENABLE]

aobscanmodule(INJECT_ADD_GIL,$process,03 C6 89 42 04) // should be unique
alloc(newmem,$1000,INJECT_ADD_GIL)

label(code)
label(return)
label(i_ig_base_addr)

newmem:
  mov [i_ig_base_addr], rdx
  cmp esi, 0
  jl code
  vcvtsi2ss xmm15, xmm15, esi
  vmovss xmm14, [vf_gil_multi]
  vmulss xmm15, xmm15, xmm14
  vcvtss2si esi, xmm15
  jmp code

@@:
  xor esi, esi

code:
  add eax,esi
  mov [rdx+04],eax
  jmp return
align 10 cc
  vf_gil_multi:
  dd (float)4
  i_ig_base_addr:
  dq 0

INJECT_ADD_GIL:
  jmp newmem
return:
registersymbol(INJECT_ADD_GIL)
registersymbol(i_ig_base_addr)

[DISABLE]

INJECT_ADD_GIL:
  db 03 C6 89 42 04

unregistersymbol(*)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+6A8F24

ffxvi.exe+6A8F0C: 72 27           - jb ffxvi.exe+6A8F35
ffxvi.exe+6A8F0E: C6 03 01        - mov byte ptr [rbx],01
ffxvi.exe+6A8F11: 89 7B 0C        - mov [rbx+0C],edi
ffxvi.exe+6A8F14: EB 5E           - jmp ffxvi.exe+6A8F74
ffxvi.exe+6A8F16: 8B 42 04        - mov eax,[rdx+04]
ffxvi.exe+6A8F19: 2B F0           - sub esi,eax
ffxvi.exe+6A8F1B: 3B FE           - cmp edi,esi
ffxvi.exe+6A8F1D: 0F 4C F7        - cmovl esi,edi
ffxvi.exe+6A8F20: 85 F6           - test esi,esi
ffxvi.exe+6A8F22: 7E 07           - jle ffxvi.exe+6A8F2B
// ---------- INJECTING HERE ----------
ffxvi.exe+6A8F24: 03 C6           - add eax,esi
// ---------- DONE INJECTING  ----------
ffxvi.exe+6A8F26: 89 42 04        - mov [rdx+04],eax
ffxvi.exe+6A8F29: EB 03           - jmp ffxvi.exe+6A8F2E
ffxvi.exe+6A8F2B: C6 03 01        - mov byte ptr [rbx],01
ffxvi.exe+6A8F2E: 89 73 08        - mov [rbx+08],esi
ffxvi.exe+6A8F31: 2B FE           - sub edi,esi
ffxvi.exe+6A8F33: EB 30           - jmp ffxvi.exe+6A8F65
ffxvi.exe+6A8F35: 3B F7           - cmp esi,edi
ffxvi.exe+6A8F37: 89 6C 24 20     - mov [rsp+20],ebp
ffxvi.exe+6A8F3B: 8B CF           - mov ecx,edi
ffxvi.exe+6A8F3D: C6 44 24 28 01  - mov byte ptr [rsp+28],01
}
</AssemblerScript>
      <CheatEntries>
        <CheatEntry>
          <ID>26</ID>
          <Description>"Last ID"</Description>
          <DropDownList DisplayValueAsItem="1">1:Gil
3:Ability pt
</DropDownList>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>FF8080</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_ig_base_addr</Address>
          <Offsets>
            <Offset>0</Offset>
          </Offsets>
        </CheatEntry>
        <CheatEntry>
          <ID>27</ID>
          <Description>"#"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>FF8080</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_ig_base_addr</Address>
          <Offsets>
            <Offset>4</Offset>
          </Offsets>
        </CheatEntry>
      </CheatEntries>
    </CheatEntry>
    <CheatEntry>
      <ID>19</ID>
      <Description>"Get XP"</Description>
      <Options moHideChildren="1"/>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>{ Game   : ffxvi.exe
  Version: 
  Date   : 2024-09-18
  Author : bbfox@https://opencheattables.com
}

[ENABLE]

aobscanmodule(INJECT_GET_XP,$process,8B 00 48 83 C4 20 5B C3 CC CC 40) // should be unique
alloc(newmem,$1000,INJECT_GET_XP)

label(code)
label(return)
label(i_xp_addr)
newmem:
  mov [i_xp_addr], rax

code:
  mov eax,[rax]
  add rsp,20
  jmp return
align 10 cc
  i_xp_addr:
  dq 0

INJECT_GET_XP:
  jmp newmem
  nop
return:
registersymbol(INJECT_GET_XP)
registersymbol(i_xp_addr)
[DISABLE]

INJECT_GET_XP:
  db 8B 00 48 83 C4 20

unregistersymbol(*)
dealloc(newmem)

{
// ORIGINAL CODE - INJECTION POINT: ffxvi.exe+452FCE

ffxvi.exe+452FAA: E8 D5 BE FF FF        - call ffxvi.exe+44EE84
ffxvi.exe+452FAF: 84 C0                 - test al,al
ffxvi.exe+452FB1: 74 0B                 - je ffxvi.exe+452FBE
ffxvi.exe+452FB3: 48 8D 4B 4C           - lea rcx,[rbx+4C]
ffxvi.exe+452FB7: B8 24 00 00 00        - mov eax,00000024
ffxvi.exe+452FBC: EB 09                 - jmp ffxvi.exe+452FC7
ffxvi.exe+452FBE: 48 8D 4B 44           - lea rcx,[rbx+44]
ffxvi.exe+452FC2: B8 1C 00 00 00        - mov eax,0000001C
ffxvi.exe+452FC7: 48 85 DB              - test rbx,rbx
ffxvi.exe+452FCA: 48 0F 45 C1           - cmovne rax,rcx
// ---------- INJECTING HERE ----------
ffxvi.exe+452FCE: 8B 00                 - mov eax,[rax]
// ---------- DONE INJECTING  ----------
ffxvi.exe+452FD0: 48 83 C4 20           - add rsp,20
ffxvi.exe+452FD4: 5B                    - pop rbx
ffxvi.exe+452FD5: C3                    - ret 
ffxvi.exe+452FD6: CC                    - int 3 
ffxvi.exe+452FD7: CC                    - int 3 
ffxvi.exe+452FD8: 40 53                 - push rbx
ffxvi.exe+452FDA: 48 83 EC 20           - sub rsp,20
ffxvi.exe+452FDE: 48 8B 0D 63 52 3C 01  - mov rcx,[ffxvi.exe+1818248]
ffxvi.exe+452FE5: 8B DA                 - mov ebx,edx
ffxvi.exe+452FE7: 4C 8B 1D FA 4C 3C 01  - mov r11,[ffxvi.exe+1817CE8]
}
</AssemblerScript>
      <CheatEntries>
        <CheatEntry>
          <ID>20</ID>
          <Description>"XP"</Description>
          <ShowAsSigned>0</ShowAsSigned>
          <Color>FF8080</Color>
          <VariableType>4 Bytes</VariableType>
          <Address>i_xp_addr</Address>
          <Offsets>
            <Offset>0</Offset>
          </Offsets>
        </CheatEntry>
      </CheatEntries>
    </CheatEntry>
    <CheatEntry>
      <ID>18</ID>
      <Description>"Final Fantasy XVI  /  https://opencheattables.com  /  CE 7.5+"</Description>
      <Color>00AE00</Color>
      <GroupHeader>1</GroupHeader>
    </CheatEntry>
  </CheatEntries>
  <UserdefinedSymbols/>
</CheatTable>
