.
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<CheatTable>
<CheatEntries>
<CheatEntry>
<ID>60</ID>
<Description>"movement mod keys"</Description>
<Options moHideChildren="1" moDeactivateChildrenAsWell="1"/>
<LastState Activated="1"/>
<Color>FF0000</Color>
<VariableType>Auto Assembler Script</VariableType>
<AssemblerScript>[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
aobscanmodule(movementSpeedCRead3AOB,GameAssembly.dll,0F ** ** EB 08 F3 0F ** ** ** ** 00 00 80 ** ** ** 00 00 00 0F 84)
registersymbol(movementSpeedCRead3AOB)
label(fWalkSpeed)
registersymbol(fWalkSpeed)
label(fJogSpeed)
registersymbol(fJogSpeed)
label(fSprintSpeed)
registersymbol(fSprintSpeed)
label(fCustomSpeed)
label(fCustomSpeedCal)
registersymbol(fCustomSpeedCal)
label(fCustomSpeedInterval)
label(bWalkKeyID)
registersymbol(bWalkKeyID)
label(bWalkKeyPressed)
registersymbol(bWalkKeyPressed)
label(bJogKeyID)
registersymbol(bJogKeyID)
label(bJogKeyPressed)
registersymbol(bJogKeyPressed)
label(bSprintKeyID)
registersymbol(bSprintKeyID)
label(bSprintKeyPressed)
registersymbol(bSprintKeyPressed)
alloc(newmem,2048,movementSpeedCRead3AOB+5) //"GameAssembly.dll"+BA5EBB)
label(returnhere)
label(originalcode_movementSpeedCRead3AOB)
registersymbol(originalcode_movementSpeedCRead3AOB)
label(exit)
newmem: //this is allocated memory, you have read,write,execute access
//place your code here
push rax
sub rsp,10
movdqu dqword [rsp],xmm0
chkwalkkey:
mov rax,fWalkSpeed
movss xmm6,[rax]
cmp byte ptr [bWalkKeyPressed],1
je docustomspeedcal
chkjogkey:
mov rax,fJogSpeed
movss xmm6,[rax]
cmp byte ptr [bJogKeyPressed],1
je docustomspeedcal
chksprintkey:
mov rax,fSprintSpeed
movss xmm6,[rax]
cmp byte ptr [bSprintKeyPressed],1
je docustomspeedcal
nomodkeypressed:
mov eax,(float)1
movd xmm6,eax
docustomspeedcal:
mov rax,fCustomSpeedCal
movss xmm0,[rax]
comiss xmm6,xmm0
ja inccustspeedcal
jb deccustspeedcal
je end
inccustspeedcal:
addss xmm0,[rax+4]
minss xmm0,xmm6
movss [rax],xmm0
jmp end
deccustspeedcal:
subss xmm0,[rax+4]
maxss xmm0,xmm6
movss [rax],xmm0
end:
readmem(movementSpeedCRead3AOB+5,8)
//movss xmm6,[rbx+a8]
mov rax,fCustomSpeedCal
mulss xmm6,xmm0
xorps xmm0,xmm0
comiss xmm6,xmm0
jne @f
//movss [rax],xmm0
//mov dword ptr [rax],(float)1
@@:
movdqu xmm0,dqword [rsp]
add rsp,10
pop rax
jmp exit
originalcode_movementSpeedCRead3AOB:
readmem(movementSpeedCRead3AOB+5,8)
//movss xmm6,[rbx+000000A8]
exit:
jmp returnhere
///
fWalkSpeed:
dd (float)0.25
fJogSpeed:
dd (float)0.5
fSprintSpeed:
dd (float)2.5
fCustomSpeed:
dd 0
fCustomSpeedCal:
dd 0
fCustomSpeedInterval:
dd (float)0.05
bWalkKeyID:
dd 12
bWalkKeyPressed:
db 0
bJogKeyID:
dd 05
bJogKeyPressed:
db 0
bSprintKeyID:
dd 06
bSprintKeyPressed:
db 0
///
movementSpeedCRead3AOB+5: //"GameAssembly.dll"+BA5EBB:
jmp newmem
nop 3
returnhere:
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
dealloc(newmem)
movementSpeedCRead3AOB+5: //"GameAssembly.dll"+BA5EBB:
readmem(originalcode_movementSpeedCRead3AOB,8)
//db F3 0F 10 B3 A8 00 00 00
//Alt: movss xmm6,[rbx+000000A8]
unregistersymbol(originalcode_movementSpeedCRead3AOB)
unregistersymbol(fWalkSpeed)
unregistersymbol(fJogSpeed)
unregistersymbol(fSprintSpeed)
unregistersymbol(fCustomSpeedCal)
unregistersymbol(bWalkKeyPressed)
unregistersymbol(bWalkKeyID)
unregistersymbol(bJogKeyPressed)
unregistersymbol(bJogKeyID)
unregistersymbol(bSprintKeyPressed)
unregistersymbol(bSprintKeyID)
</AssemblerScript>
<CheatEntries>
<CheatEntry>
<ID>61</ID>
<Description>"walk key"</Description>
<Options moHideChildren="1"/>
<LastState Activated="1"/>
<Color>FF0000</Color>
<VariableType>Auto Assembler Script</VariableType>
<AssemblerScript>[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
bWalkKeyID:
dd 12
fWalkSpeed:
dd (float)0.25
//modified from ShyTwig16's lua keylistener script
//http://fearlessrevolution.com/viewtopic.php?f=4&t=6041&start=60#p62657
{$lua}
local function walkKeyLuaThread(thread2)
local addr1 = getAddressSafe('bWalkKeyPressed')
while WalkkeyLuaThreadLoop do
sleep(100)
if addr1 then
if ( isKeyPressed( readInteger('bWalkKeyID') ) ) then
writeBytes(addr1, 1)
else
writeBytes(addr1, 0)
end
else
addr1 = getAddressSafe('bWalkKeyPressed')
end
end
thread2.terminate()
-- while WalkkeyLuaThreadLoop do
-- if ( isKeyPressed(VK_CAPITAL) ) then
-- writeBytes("bWalkKeyPressed" ,1)
-- else
-- writeBytes("bWalkKeyPressed" ,0)
-- end
-- end
-- thread2.terminate()
end
----------------------------------
if syntaxcheck then return end
WalkkeyLuaThreadLoop = true
createThread(walkKeyLuaThread)
{$asm}
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
{$lua}
if syntaxcheck then return end
WalkkeyLuaThreadLoop = false
{$asm}
</AssemblerScript>
<CheatEntries>
<CheatEntry>
<ID>167</ID>
<Description>"key"</Description>
<DropDownList ReadOnly="1" DescriptionOnly="1" DisplayValueAsItem="1">05:X1 mouse button
06:X2 mouse button
10:SHIFT key
11:CTRL key
12:ALT key
14:CAPS LOCK key
</DropDownList>
<LastState Value="12" RealAddress="7FEABCA00FC"/>
<ShowAsHex>1</ShowAsHex>
<Color>008000</Color>
<VariableType>Byte</VariableType>
<Address>bWalkKeyID</Address>
</CheatEntry>
<CheatEntry>
<ID>163</ID>
<Description>"walk speed"</Description>
<LastState Value="0.25" RealAddress="7FEABCA00E4"/>
<Color>008000</Color>
<VariableType>Float</VariableType>
<Address>fWalkSpeed</Address>
</CheatEntry>
</CheatEntries>
</CheatEntry>
<CheatEntry>
<ID>63</ID>
<Description>"jog key"</Description>
<Options moHideChildren="1"/>
<LastState Activated="1"/>
<Color>FF0000</Color>
<VariableType>Auto Assembler Script</VariableType>
<AssemblerScript>[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
bJogKeyID:
dd 05
fJogSpeed:
dd (float)0.5
//modified from ShyTwig16's lua keylistener script
//http://fearlessrevolution.com/viewtopic.php?f=4&t=6041&start=60#p62657
{$lua}
local function jogKeyLuaThread(thread2)
local addr3 = getAddressSafe('bJogKeyPressed')
while RunkeyLuaThreadLoop do
sleep(100)
if addr3 then
if ( isKeyPressed( readInteger('bJogKeyID') ) ) then
writeBytes(addr3, 1)
else
writeBytes(addr3, 0)
end
else
addr3 = getAddressSafe('bJogKeyPressed')
end
end
thread2.terminate()
-- while RunkeyLuaThreadLoop do
-- if ( isKeyPressed(VK_CAPITAL) ) then
-- writeBytes("bJogKeyPressed" ,1)
-- else
-- writeBytes("bJogKeyPressed" ,0)
-- end
-- end
-- thread2.terminate()
end
----------------------------------
if syntaxcheck then return end
RunkeyLuaThreadLoop = true
createThread(jogKeyLuaThread)
{$asm}
///*****************************************///
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
{$lua}
if syntaxcheck then return end
RunkeyLuaThreadLoop = false
{$asm}
</AssemblerScript>
<CheatEntries>
<CheatEntry>
<ID>168</ID>
<Description>"key"</Description>
<DropDownList ReadOnly="1" DescriptionOnly="1" DisplayValueAsItem="1">05:X1 mouse button
06:X2 mouse button
10:SHIFT key
11:CTRL key
12:ALT key
14:CAPS LOCK key
</DropDownList>
<LastState Value="05" RealAddress="7FEABCA0101"/>
<ShowAsHex>1</ShowAsHex>
<Color>008000</Color>
<VariableType>Byte</VariableType>
<Address>bJogKeyID</Address>
</CheatEntry>
<CheatEntry>
<ID>169</ID>
<Description>"jog speed"</Description>
<LastState Value="0.5" RealAddress="7FEABCA00E8"/>
<Color>008000</Color>
<VariableType>Float</VariableType>
<Address>fJogSpeed</Address>
</CheatEntry>
</CheatEntries>
</CheatEntry>
<CheatEntry>
<ID>62</ID>
<Description>"sprint key"</Description>
<Options moHideChildren="1"/>
<LastState Activated="1"/>
<Color>FF0000</Color>
<VariableType>Auto Assembler Script</VariableType>
<AssemblerScript>[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
bJogKeyPressed:
db 0
fSprintSpeed:
dd (float)2.5
//modified from ShyTwig16's lua keylistener script
//http://fearlessrevolution.com/viewtopic.php?f=4&t=6041&start=60#p62657
{$lua}
local function sprintKeyLuaThread(thread2)
local addr2 = getAddressSafe('bSprintKeyPressed')
while RunkeyLuaThreadLoop do
sleep(100)
if addr2 then
if ( isKeyPressed( readInteger('bSprintKeyID') ) ) then
writeBytes(addr2, 1)
else
writeBytes(addr2, 0)
end
else
addr2 = getAddressSafe('bSprintKeyPressed')
end
end
thread2.terminate()
-- while RunkeyLuaThreadLoop do
-- if ( isKeyPressed(VK_CAPITAL) ) then
-- writeBytes("bSprintKeyPressed" ,1)
-- else
-- writeBytes("bSprintKeyPressed" ,0)
-- end
-- end
-- thread2.terminate()
end
----------------------------------
if syntaxcheck then return end
RunkeyLuaThreadLoop = true
createThread(sprintKeyLuaThread)
{$asm}
///*****************************************///
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
{$lua}
if syntaxcheck then return end
RunkeyLuaThreadLoop = false
{$asm}
</AssemblerScript>
<CheatEntries>
<CheatEntry>
<ID>170</ID>
<Description>"key"</Description>
<DropDownList ReadOnly="1" DescriptionOnly="1" DisplayValueAsItem="1">05:X1 mouse button
06:X2 mouse button
10:SHIFT key
11:CTRL key
12:ALT key
14:CAPS LOCK key
</DropDownList>
<LastState Value="06" RealAddress="7FEABCA0106"/>
<ShowAsHex>1</ShowAsHex>
<Color>008000</Color>
<VariableType>Byte</VariableType>
<Address>bSprintKeyID</Address>
</CheatEntry>
<CheatEntry>
<ID>171</ID>
<Description>"sprint speed"</Description>
<LastState Value="2.5" RealAddress="7FEABCA00EC"/>
<Color>008000</Color>
<VariableType>Float</VariableType>
<Address>fSprintSpeed</Address>
</CheatEntry>
</CheatEntries>
</CheatEntry>
<CheatEntry>
<ID>104013</ID>
<Description>"fly key"</Description>
<Options moHideChildren="1"/>
<LastState Activated="1"/>
<Color>FF0000</Color>
<VariableType>Auto Assembler Script</VariableType>
<AssemblerScript>[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
aobscanmodule(someDeltaReadAOB,GameAssembly.dll,48 ** ** E8 ** ** ** ** 48 ** ** ** ** ** ** F6 ** ** ** 00 00 02 74 ** 83 ** ** ** 00 00 00 75 05 E8 ** ** ** ** F3 0F ** ** ** ** 0F ** ** F3 0F ** ** ** ** F3 0F ** ** ** ** 0F ** ** F2 0F)
registersymbol(someDeltaReadAOB)
///
aobscanmodule(playerDeltaReadCallerAOB,GameAssembly.dll,48 ** ** ** ** ** ** ** E8 ** ** ** ** 48 ** ** ** ** ** ** ** 0F ** ** ** ** 0F ** ** ** ** 44)
registersymbol(playerDeltaReadCallerAOB)
///
label(pPlayerInfo1)
registersymbol(pPlayerInfo1)
label(bHoverKeyID)
registersymbol(bHoverKeyID)
label(bHoverKeyPressed)
registersymbol(bHoverKeyPressed)
label(bUpKeyPressed)
registersymbol(bUpKeyPressed)
label(dUpSpeed)
registersymbol(dUpSpeed)
label(bDownKeyPressed)
registersymbol(bDownKeyPressed)
label(dDownSpeed)
registersymbol(dDownSpeed)
label(dVerticalSpeedCal)
registersymbol(dVerticalSpeedCal)
label(dVerticalSpeedInterval)
registersymbol(dVerticalSpeedInterval)
alloc(newmem,2048,someDeltaReadAOB+26) //"GameAssembly.dll"+10D0437)
label(returnhere)
label(originalcode_someDeltaReadAOB)
registersymbol(originalcode_someDeltaReadAOB)
label(exit)
newmem: //this is allocated memory, you have read,write,execute access
//place your code here
//mov rdi,"GameAssembly.dll"+BA3D15
mov rdi,playerDeltaReadCallerAOB
lea rdi,[rdi+d]
cmp [rsp+58],rdi
jne @f
mov rdi,pPlayerInfo1
mov [rdi],rbx
@@:
mov rdi,pPlayerInfo1
cmp [rdi],rbx
jne end
mov rdi,bHoverKeyPressed
cmp byte ptr [rdi],1
jne end
mov rdi,bDownKeyPressed
cmp byte ptr [rdi],1
//je end
movss xmm1,[rdi+4]
je @f
//xorps xmm1,xmm1
//comiss xmm1,[rsp+64]
//jbe @f
//movss [rsp+64],xmm1
//@@:
mov rdi,bUpKeyPressed
cmp byte ptr [rdi],1
movss xmm1,[rdi+4]
je @f
xorps xmm1,xmm1
@@:
mov rdi,dVerticalSpeedCal
movss xmm0,[rdi]
comiss xmm1,xmm0
ja incvspeedcal
jb decvspeedcal
je vspeedcalend
incvspeedcal:
addss xmm0,[rdi+4]
minss xmm0,xmm1
movss [rdi],xmm0
jmp vspeedcalend
decvspeedcal:
subss xmm0,[rdi+4]
maxss xmm0,xmm1
movss [rdi],xmm0
vspeedcalend:
//comiss xmm1,[rsp+64]
//jbe @f
mov rdi,fCustomSpeedCal
mulss xmm0,[rdi]
readmem(someDeltaReadAOB+26,2)
db 5F 44
readmem(someDeltaReadAOB+2a,2)
//maxss xmm0,[rsp+64]
readmem(someDeltaReadAOB+26,2)
db 11 44
readmem(someDeltaReadAOB+2a,2)
//movss [rsp+64],xmm0
@@:
end:
originalcode_someDeltaReadAOB:
readmem(someDeltaReadAOB+26,6)
//movss xmm1,[rsp+64]
exit:
jmp returnhere
///
pPlayerInfo1:
dq 0
bHoverKeyID:
dd 10
bHoverKeyPressed:
dd 0
bUpKeyPressed:
dd 0
dUpSpeed:
dd (float)10
bDownKeyPressed:
dd 0
dDownSpeed:
dd (float)-10
dVerticalSpeedCal:
dd 0
dVerticalSpeedInterval:
dd (float)0.1
///
someDeltaReadAOB+26: //"GameAssembly.dll"+10D0437:
jmp newmem
nop
returnhere:
///*****************************************///
//modified from ShyTwig16's lua keylistener script
//http://fearlessrevolution.com/viewtopic.php?f=4&t=6041&start=60#p62657
{$lua}
local function flyKeysLuaThread(thread2)
local addr10 = getAddressSafe('bHoverKeyPressed')
local addr11 = getAddressSafe('bUpKeyPressed')
local addr12 = getAddressSafe('bDownKeyPressed')
while FlyKeysLuaThreadLoop do
sleep(100)
if addr10 then
if ( isKeyPressed( readInteger('bHoverKeyID') ) ) then
writeBytes(addr10, 1)
else
writeBytes(addr10, 0)
end
else
addr10 = getAddressSafe('bHoverKeyPressed')
end
if addr11 then
if ( isKeyPressed(VK_W) ) then
writeBytes(addr11, 1)
else
writeBytes(addr11, 0)
end
else
addr11 = getAddressSafe('bUpKeyPressed')
end
if addr12 then
if ( isKeyPressed(VK_S) ) then
writeBytes(addr12, 1)
else
writeBytes(addr12, 0)
end
else
addr12 = getAddressSafe('bDownKeyPressed')
end
end
thread2.terminate()
-- while FlyKeysLuaThreadLoop do
-- if ( isKeyPressed(VK_CAPITAL) ) then
-- writeBytes("bHoverKeyPressed" ,1)
-- else
-- writeBytes("bHoverKeyPressed" ,0)
-- end
-- end
-- thread2.terminate()
end
----------------------------------
if syntaxcheck then return end
FlyKeysLuaThreadLoop = true
createThread(flyKeysLuaThread)
{$asm}
///*****************************************///
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
{$lua}
if syntaxcheck then return end
FlyKeysLuaThreadLoop = false
{$asm}
///*****************************************///
dealloc(newmem)
someDeltaReadAOB+26: //"GameAssembly.dll"+10D0437:
readmem(originalcode_someDeltaReadAOB,6)
//db F3 0F 10 4C 24 64
//Alt: movss xmm1,[rsp+64]
unregistersymbol(originalcode_someDeltaReadAOB)
unregistersymbol(pPlayerInfo1)
unregistersymbol(bHoverKeyID)
unregistersymbol(bHoverKeyPressed)
unregistersymbol(bUpKeyPressed)
unregistersymbol(dUpSpeed)
unregistersymbol(bDownKeyPressed)
unregistersymbol(dDownSpeed)
unregistersymbol(dVerticalSpeedCal)
unregistersymbol(dVerticalSpeedInterval)
///*****************************************///
</AssemblerScript>
<CheatEntries>
<CheatEntry>
<ID>104015</ID>
<Description>"key"</Description>
<DropDownList ReadOnly="1" DescriptionOnly="1" DisplayValueAsItem="1">05:X1 mouse button
06:X2 mouse button
10:SHIFT key
11:CTRL key
12:ALT key
14:CAPS LOCK key
</DropDownList>
<LastState Value="10" RealAddress="7FEABC900EE"/>
<ShowAsHex>1</ShowAsHex>
<Color>008000</Color>
<VariableType>Byte</VariableType>
<Address>bHoverKeyID</Address>
</CheatEntry>
</CheatEntries>
</CheatEntry>
</CheatEntries>
</CheatEntry>
</CheatEntries>
</CheatTable>
(default: Shift) to hover, then use WASD to fly around.
if you have activated one of the other 3 mod key scripts, fly around would benefit from the speed multiplier as well.
smoothed speed is implemented to match the game's default speed acceleration/deceleration of mid-air left/right movement. (just the same simple algorithm I used for the smooth speed change between walk/jog/sprint speed...)
note that I'm still at the very start of the game, the script might interfere some in-air action later on, depends on how similar the skills and control comparing to the first game are.