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 


I created a trainer. It worked twice. continuous' Error-Stri

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
AylinCE
Grandmaster Cheater Supreme
Reputation: 32

Joined: 16 Feb 2017
Posts: 1259

PostPosted: Thu Feb 16, 2017 3:34 am    Post subject: I created a trainer. It worked twice. continuous' Error-Stri Reply with quote

Error:[string "function CreateTrainer()
..."]:196: attempt to call a nil value (field 'mod')
Error:[string "function CreateTrainer()
..."]:196: attempt to call a nil value (field 'mod')
----------------------------------------------------------
Thanks for the coach. I made a cheat engine, it worked 1-2 times. But it always does not work with the error messages above! I tried CE 6.3 and 6.6 but only worked 1-2 times. What causes the above faults? Thank you already for your joy when you help
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
mgr.inz.Player
I post too much
Reputation: 218

Joined: 07 Nov 2008
Posts: 4438
Location: W kraju nad Wisla. UTC+01:00

PostPosted: Thu Feb 16, 2017 5:58 am    Post subject: Reply with quote

add this at the beginning:
Code:
math.mod=math.fmod

_________________
Back to top
View user's profile Send private message MSN Messenger
AylinCE
Grandmaster Cheater Supreme
Reputation: 32

Joined: 16 Feb 2017
Posts: 1259

PostPosted: Thu Feb 16, 2017 11:12 am    Post subject: Reply with quote

mgr.inz.Player wrote:
add this at the beginning:
Code:
math.mod=math.fmod



thanks..
What line should I add to this string per line?

Error:[string "Math.mod = math.fmod..."]:1: attempt to index global 'Math' (a nil value)
Error:[string "function CreateTrainer()..."]:196: attempt to index global 'Math' (a nil value)
Error:[string "function CreateTrainer()..."]:196: attempt to index global 'Math' (a nil value)

The error message now focuses on math mode ..

HackData:Info()
end
function DEC_HEX(IN)
local B,K,OUT,I,D=16,"0123456789ABCDEF","",0
if IN<1 then
OUT=0
return OUT
end
while IN>0 do
I=I+1
Math.mod = math.fmod
IN,D=math.floor(IN/B),math.mod(IN,B)+1
OUT=string.sub(K,D,D)..OUT
end
return OUT
end
function Aobswap(search, change)
aobs = AOBScan(search)
if(aobs ~= nil) then
j = stringlist_getCount(aobs)
for i = 1, j do
address=stringlist_getString(aobs,i-1)
for i = 1, string.len(change), 3 do
z = string.sub(change, i, i+2)
x, y = string.find(z, "%?+")
if (x == nil) then
script=[[
]]..address.."+"..(DEC_HEX((i-1)/3))..[[:
db ]]..z..[[
]]
autoAssemble(script)
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Dark Byte
Site Admin
Reputation: 458

Joined: 09 May 2003
Posts: 25296
Location: The netherlands

PostPosted: Thu Feb 16, 2017 11:46 am    Post subject: Reply with quote

case matters
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
AylinCE
Grandmaster Cheater Supreme
Reputation: 32

Joined: 16 Feb 2017
Posts: 1259

PostPosted: Thu Feb 16, 2017 12:33 pm    Post subject: Reply with quote

Thank you. It was a great analysis and it worked. Razz
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites