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 


CE Trainer closes the second it opens

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
Reclaimer Shawn
Advanced Cheater
Reputation: 0

Joined: 09 Jun 2015
Posts: 77

PostPosted: Mon Aug 22, 2016 9:33 pm    Post subject: CE Trainer closes the second it opens Reply with quote

So, after testing my trainer, it closes immediately after opening. I found out that it was due to this line of code:

Code:



Could you all tell me what is wrong? Thanks!


Last edited by Reclaimer Shawn on Tue Aug 23, 2016 10:09 pm; edited 1 time in total
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Mon Aug 22, 2016 9:41 pm    Post subject: Reply with quote

Probably your addresses. Learn about array of bytes (AOB).
Back to top
View user's profile Send private message
Reclaimer Shawn
Advanced Cheater
Reputation: 0

Joined: 09 Jun 2015
Posts: 77

PostPosted: Mon Aug 22, 2016 9:44 pm    Post subject: Reply with quote

Zanzer wrote:
Probably your addresses. Learn about array of bytes (AOB).

The addresses are correct as the work 100% of the time in a Cheat Table. Also, I wanted to infinitely Lopp aforementioned code when checked. If not checked, it won't loop. This is a checkbox by the way. Also, AOB Scan wouldn'the work as there are literally 400+ Byte structures with the same format. It also gives me no time to press any button on the software, either.
Back to top
View user's profile Send private message
predprey
Master Cheater
Reputation: 24

Joined: 08 Oct 2015
Posts: 486

PostPosted: Mon Aug 22, 2016 10:07 pm    Post subject: Reply with quote

i reckon you did not paste the function "as is" since there are 3 ends but what you posted only required 2?
Back to top
View user's profile Send private message
Reclaimer Shawn
Advanced Cheater
Reputation: 0

Joined: 09 Jun 2015
Posts: 77

PostPosted: Tue Aug 23, 2016 6:12 pm    Post subject: Reply with quote

predprey wrote:
i reckon you did not paste the function "as is" since there are 3 ends but what you posted only required 2?


Was playing around with it a bit trying to get it to work, but I must've copy and pasted wrong somewhere. Without the Checkbox1 Statement, the entire program works fine. Have to assume it's something wrong there.


Last edited by Reclaimer Shawn on Tue Aug 23, 2016 10:08 pm; edited 1 time in total
Back to top
View user's profile Send private message
predprey
Master Cheater
Reputation: 24

Joined: 08 Oct 2015
Posts: 486

PostPosted: Tue Aug 23, 2016 8:53 pm    Post subject: Reply with quote

try moving "function code()" outside of CECheckbox1Change? or you can replace timer_onTimer(t,code) with

timer_onTimer(t,
function ()
writeBytes("804990D3",73)
writeBytes("80499018",0,249)
writeBytes("8049901C",127,255)
writeBytes("804990A8",127,255)
writeBytes("804990AA",255,255)
writeBytes("804990AC",255,255)
writeBytes("804990AE",255,255)
writeBytes("804990B0",255,255)
writeBytes("804990B2",255,255)
end
)
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 458

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

PostPosted: Tue Aug 23, 2016 9:27 pm    Post subject: Reply with quote

save it as an unprotected .cetrainer and see if it closes when you run that. (that way you can see if it's a missing file, or your script)
_________________
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
Reclaimer Shawn
Advanced Cheater
Reputation: 0

Joined: 09 Jun 2015
Posts: 77

PostPosted: Tue Aug 23, 2016 10:07 pm    Post subject: Reply with quote

Dark Byte wrote:
save it as an unprotected .cetrainer and see if it closes when you run that. (that way you can see if it's a missing file, or your script)

DBK was the problem. I just made a table to apply the script to my trainer after it runs, so DBK_INITIALIZE code doesn'the get in the way of the initial starting of the problem. A bit of a workaround.
Back to top
View user's profile Send private message
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