Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Cheat Engine Forum Index
PostGo back to topic
zxuiji
Advanced Cheater
Reputation: 1
Joined: 26 Sep 2016
Posts: 70

PostPosted: Sun Jan 07, 2018 6:26 am    Post subject:

Got it! (I think :D) For reference here's my code:
Code:

function zAOBAddr( T, ADDSUB )
   if ( (T == nil ) or (T.Count == 0) ) then
        return nil
   end
   return ('' .. T[0] .. '' .. ADDSUB)
end

function zSymbol( name, value )
         if ( name == nil ) then return end
         unregisterSymbol( name )
         if ( (value == nil) or (value == 0) ) then return end
         registerSymbol( name, value )
end

local zHP_AOB = AOBScan("8B 80 98 0C 00 00 E9")
local zFoes_AOB = AOBScan("A0 A0 00 00 A1 2F 00 00")

local zHP = zAOBAddr( zHP_AOB, '-4' )
local pFoes = zAOBAddr( zFoes_AOB, '' )

local pHP = readInteger(zHP)
local rHP = '' .. (pHP or 0) .. '+9C8'

zSymbol( 'pHP', pHP )
zSymbol( 'pFoes', pFoes )

Further issues should be just lua related for the time being but this is enough to get me started on the semi-expert phase. I'll check back later in case a potential problem is spotted and pointed it out in another post.
_________________
Those who do not trust in christ to save them from their sins will only experience hell when their soul is released from it's earthly vessel.
Back to top
View user's profile Send private message
Post reviews:   Approve 1
Author Review
TheyCallMeTim13
Review: Approve
Post reference:
ReviewPosted: Sun Jan 07, 2018 2:58 pm

Learning to fish.
Back to top
View user's profile Send private message Visit poster's website
Display:  
Cheat Engine Forum Index


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites