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 


small script

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
fearZ
How do I cheat?
Reputation: 0

Joined: 17 Jan 2015
Posts: 3

PostPosted: Sat Jan 17, 2015 5:28 am    Post subject: small script Reply with quote

Hey guys, I need a script to display the value in the edit box.


script.png
 Description:
 Filesize:  12.19 KB
 Viewed:  4398 Time(s)

script.png


Back to top
View user's profile Send private message
DaSpamer
Grandmaster Cheater Supreme
Reputation: 52

Joined: 13 Sep 2011
Posts: 1578

PostPosted: Sat Jan 17, 2015 5:05 pm    Post subject: Reply with quote

Not sure how to read 2 bytes.. but heres a method no function for that yet.
Code:
local t = readBytes(0x1FB1022,true)
local v = tonumber('0x'..string.format("%x",t[2])..string.format("%x",t[1]))
CETRAINER.CEEdit1.Text = v;


Another method would is finding that memory record and getting its value

_________________
HEY Hitler
Do you get lazy when making trainers?
Well no more!
My CETrainer will generate it for you in seconds, so you won't get lazy! Very Happy

http://forum.cheatengine.org/viewtopic.php?t=564919
Back to top
View user's profile Send private message
mgr.inz.Player
I post too much
Reputation: 218

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

PostPosted: Sat Jan 17, 2015 8:34 pm    Post subject: Reply with quote

@DaSpamer

Code:
local v = bAnd( readInteger(0x1FB1022) , 0xFFFF )


Or you can define this function:
Code:
function readWord(a)
  return bAnd(readInteger(a),0xFFFF)
end


Then
Code:
local v = readWord(0x1FB1022)

_________________
Back to top
View user's profile Send private message MSN Messenger
Dark Byte
Site Admin
Reputation: 457

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

PostPosted: Sat Jan 17, 2015 8:42 pm    Post subject: Reply with quote

byteTableToWord is an possibility as well
_________________
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
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