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 


What am I doing wrong? Infinite HP Script

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

Joined: 26 May 2016
Posts: 4
Location: United States

PostPosted: Thu May 26, 2016 11:17 am    Post subject: What am I doing wrong? Infinite HP Script Reply with quote

I'm super curious what I'm doing wrong. I've looked at plenty of examples, but admittedly don't know very much about LUA scripting.

Code:
[ENABLE]

aobscan(MyHP,89 08 8B 05 AC 7F F7 0D) // should be unique
alloc(newmem,$1000)

label(code)
label(return)

newmem:

code:
  mov [eax],ecx
  mov eax,[0DF77FAC],Int(100)
  jmp return

MyHP:
  jmp code
  nop
  nop
  nop
return:
registersymbol(MyHP)

[DISABLE]

MyHP:
  db 89 08 8B 05 AC 7F F7 0D

unregistersymbol(MyHP)
dealloc(newmem)


Could someone please help and if so thank you.

_________________
Rogue-likes and RPGs <3
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: Thu May 26, 2016 11:42 am    Post subject: Reply with quote

1) this is not Lua script. It is autoassemble script.

2) this is wrong
Code:
mov eax,[0DF77FAC],Int(100)


Original lines are:
Code:
  mov [eax],ecx
  mov eax,[0DF77FAC]



And the question. Do you want to overwrite value pointed by eax in the first line?
Code:
  mov [eax],(int)100
  mov eax,[0DF77FAC]



, or maybe overwrite eax at the second line
Code:
  mov [eax],ecx
  mov eax,(int)100



or write that value into [0DF77FAC] ?
Code:
  mov [eax],ecx
  mov [0DF77FAC],(int)100

_________________
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