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 


How to re-attach in a cheat table
Goto page Previous  1, 2
 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
DaSpamer
Grandmaster Cheater Supreme
Reputation: 52

Joined: 13 Sep 2011
Posts: 1578

PostPosted: Wed Nov 18, 2020 6:59 am    Post subject: Reply with quote

Using pattern matching to find the game process (as long as it has some sort of rule), reduces a bit the hassle, so yeah definitely look into that, using createOpenDialog just to get process name is quite an overkill (unless you also start the process for various reasons).

I have overlooked the part of the image, apologizes,
You may look into the getACProcess function, may replace the getProcessIDFromProcessName, you can change so it would return process id and check if the process id still the same,
you may modify it to return all matching processes (create an array, insert into the table all matching process with process id + process name), and check if new process has spawned and perhaps attach to it.

Feel free to open a topic regarding your issues, I will happily help you as well as many other amazing fellows here.

_________________
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
paul44
Expert Cheater
Reputation: 2

Joined: 20 Jul 2017
Posts: 152

PostPosted: Wed Nov 25, 2020 2:02 am    Post subject: some feedback Reply with quote

^ saw your reply this weekend, but a bit busy...

anyways: what you did not know is, that I'm using a "settings page" since a few months now (see here: [ https://www.dropbox.com/s/z6ubfzmd974buhk/ACBF_SettingsPage.jpg?dl=0 ])
Basically: anything that was hardcoded in the CT LS window, has now been parameterized. the 1st part can be updated by the user him/herself; 2nd part by CT author (= me Smile) (~ well, gamer can obviously access all of this, but at own risk, sort of speak).
As you can see in the 'users' section, the game's exe can be changed in here (if needed ~ this used to "sit" in the CT LS to autoattach the game). My approach is - from a user's point of view - that s/he can "extend" that name to one's own liking (for whatever reason) Again: primarily done for myself, to ease attaching the proper exe (f.e. I have 'Win' exe versions of all my x32 AC titles, just for debugging purposes)
btw, here is a small detail: since I came across the 'onOpenProcess' fn, I no longer needed the 'OpenDialog'; but have then decided to use it as "game_launcher"... (hence the addition of a 'full_path' field; which can be filled in here by the gamer, or done automatically upon 1st attach-ing)

But the main reason, I replied: "I will happily help you as well as many other amazing fellows here"... To say it in my own/others words: "thank your god(s) for the fact that you martians do come down to earth now and then, and join us native earthlings here on this 3rd rock from the sun" Cool
Back to top
View user's profile Send private message
DaSpamer
Grandmaster Cheater Supreme
Reputation: 52

Joined: 13 Sep 2011
Posts: 1578

PostPosted: Wed Nov 25, 2020 2:27 am    Post subject: This post has 1 review(s) Reply with quote

Quote:
But the main reason, I replied: "I will happily help you as well as many other amazing fellows here"... To say it in my own/others words: "thank your god(s) for the fact that you martians do come down to earth now and then, and join us native earthlings here on this 3rd rock from the sun" Cool


Oh I didn't mean it in any such way,
I was trying to encourage you to post a thread, in a supportive and encouraging way, so we could help you get the desired result and share knowledge and different ways to accomplish the very same results, instead of pick pointing parts of code over the span of 3 months, and also benefiting future users whom may struggle with the very same issue.

If you look in my past threads, you would see that I was clueless about many functions and approaches, and there weren't so much topics regarding the subject(s),Dark Byte and mgr.inz.player helped me in most of those tasks and I'm grateful for them, so I'm just passing further down my knowledge.

_________________
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
ByTransient
Expert Cheater
Reputation: 5

Joined: 05 Sep 2020
Posts: 240

PostPosted: Wed Nov 25, 2020 2:38 am    Post subject: Reply with quote

DaSpamer wrote:
...


I won't add much, with the description below, +1 is yours.

" You are one of the masters I want to see at CEF.
Honest and helpful.
It's a big gain to have you here. Thank you."
Back to top
View user's profile Send private message
paul44
Expert Cheater
Reputation: 2

Joined: 20 Jul 2017
Posts: 152

PostPosted: Wed Nov 25, 2020 1:11 pm    Post subject: a complement it was :) This post has 1 review(s) Reply with quote

^ Well, you misread my reply then, since I was definitely complementing chaps like yourself (or i'm misreading your reply Embarassed ~ the challenge of any electronic communication/medium). and yeah: what might seem "basic" to some, is a mountain-to-climb for others. But don't you worry: if I can't find something or I can't grasp it, I will post my problem... for sure.

That said: I like to try/research things myself first, for several reasons: a) better understand the underlaying problem so that I can formulate better b) pick up the momentum/experience that one needs to "move about" in this (particular) CE environment and - last but not least - c) tap myself on the shoulder, when i figured it out by myself of course (earthling and all, you know Smile)

Bottomline: like #ByTransient said... Wink
Back to top
View user's profile Send private message
paul44
Expert Cheater
Reputation: 2

Joined: 20 Jul 2017
Posts: 152

PostPosted: Sat Jan 16, 2021 4:49 am    Post subject: close/disable alls scripts (incl locked values) using Lua Reply with quote

1. 'auto-closing' mem_records: v7x does a great job, apart from the 'locked values'. (see my post on prev page)

I had this still on my Todo list: basically, if one disables a script manually, CE will close all "sub"-scripts (if set accordingly) AND "unlock" any locked values/mem_records. However - upto v7.2 - Lua does not unlock 'locked values'.

Well, it... euhmm... came to me yesterday evening, while lying in bed... having sex...: whatif I use a 'hotkey'? will that do the trick?

{$lua}
keyDown(VK_CONTROL)
doKeyPress(VK_F12)
keyUp(VK_CONTROL)

This seems to do the trick (correct me if this can/could introduce unexpected behaviour), but I was wondering if something like {doKeyPress(VK_CONTROL + VK_F12)} is possible too? (did try it though ~ I want a combo keypress as this makes it less likely to conflict with one's configuration)

ps: everything mentioned above is true, apart from the sex... I'm afraid Rolling Eyes

-EDIT-
After some more testing, it turns out the 'hotkey' does not do the job either. Locked some additional values in several subsections, and some of them did not get unlocked...
So, evt decided to 'parcours' all of them to get them disabled:

[code]
for i=0,al.Count-1 do
al[i].Active = false
end
[/code]
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
Goto page Previous  1, 2
Page 2 of 2

 
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