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 


No Firest RUn CT in cheat Engine. pleaase Help!!

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

Joined: 14 Apr 2024
Posts: 9

PostPosted: Sun Apr 14, 2024 12:12 pm    Post subject: No Firest RUn CT in cheat Engine. pleaase Help!! Reply with quote

Hi.
I have written a simple code in cheat engine that I save as CT. Whenever I close the cheat engine and open it again and run the CT file and click on icon, no message is displayed. However, if I keep the chat open and run CT for the second , a message will be displayed by clicking on the item. Why does it fail the first time???



Code:
local form = createForm(true)

form.Caption = 'test'
form.Height = 380
form.Width = 514

-------------------------------------------
local myText = createEdit(form)
myText.ReadOnly = true
myText.Color =  0xF0000
myText.Font.Size = 11
myText.Font.Color = 0x00FFFF
myText.Height = 8
myText.Width = 300
myText.Top = 4
myText.Left = 100
myText.Text = " WELLCOME "

--------------------------------------------------------

local CEPanel1 = createPanel(form) --
CEPanel1.Font.Size = 14
CEPanel1.Font.Color = 0X0FFF0
CEPanel1.Font.Bold = true
CEPanel1.Caption = '               please click                                   '
CEPanel1.Top = 33
CEPanel1.Left = 30
CEPanel1.Height = 40
CEPanel1.Width = 220

local buttonYes = createButton(form)
buttonYes.Caption = 'ON'
buttonYes.Color = 0x000FBA
buttonYes.Height = 24
buttonYes.Left = 143
buttonYes.Top = 42
buttonYes.Width = 48
buttonYes.OnClick = He


local buttonNo = createButton(form)
buttonNo.Caption = 'OFF'
buttonNo.Height = 24
buttonNo.Left = 195
buttonNo.Top = 42
buttonNo.Width = 48
buttonNo.OnClick = Hea

   function He()
   showMessage("Activad")
   end

   function Hea()
   showMessage(" Disabled")
   end
Back to top
View user's profile Send private message
AylinCE
Grandmaster Cheater Supreme
Reputation: 33

Joined: 16 Feb 2017
Posts: 1316

PostPosted: Sun Apr 14, 2024 12:52 pm    Post subject: Reply with quote

The first time it just detects it as "Local" and saves it.
However, since the order in which the function is assigned to the button is incorrect, it does not detect it the first time.

First create the function, then assign it to a control.

Code:

   function He()
   showMessage("Activad")
   end

   function Hea()
   showMessage(" Disabled")
   end

buttonYes.OnClick = He
buttonNo.OnClick = Hea


use:
Code:
 if form then form.Destroy() end -- Do not multiply the same sample!
form = createForm(MainForm) -- The testing phase is; MainForm else createForm() sufficient.


form.Caption = 'test'
form.Height = 380
form.Width = 514

-------------------------------------------
local myText = createEdit(form)
myText.ReadOnly = true
myText.Color =  0xF0000
myText.Font.Size = 11
myText.Font.Color = 0x00FFFF
myText.Height = 8
myText.Width = 300
myText.Top = 4
myText.Left = 100
myText.Text = " WELLCOME "

--------------------------------------------------------

local CEPanel1 = createPanel(form) --
CEPanel1.Font.Size = 14
CEPanel1.Font.Color = 0X0FFF0
CEPanel1.Font.Bold = true
CEPanel1.Caption = '               please click                                   '
CEPanel1.Top = 33
CEPanel1.Left = 30
CEPanel1.Height = 40
CEPanel1.Width = 220

local buttonYes = createButton(form)
buttonYes.Caption = 'ON'
buttonYes.Color = 0x000FBA
buttonYes.Height = 24
buttonYes.Left = 143
buttonYes.Top = 42
buttonYes.Width = 48


local buttonNo = createButton(form)
buttonNo.Caption = 'OFF'
buttonNo.Height = 24
buttonNo.Left = 195
buttonNo.Top = 42
buttonNo.Width = 48

   function He()
   showMessage("Activad")
   end

   function Hea()
   showMessage(" Disabled")
   end

buttonYes.OnClick = He
buttonNo.OnClick = Hea

_________________
Hi Hitler Different Trainer forms for you!
https://forum.cheatengine.org/viewtopic.php?t=619279
Enthusiastic people: Always one step ahead
Do not underestimate me Master: You were a beginner in the past
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Sol.gaming
How do I cheat?
Reputation: 0

Joined: 14 Apr 2024
Posts: 9

PostPosted: Sun Apr 14, 2024 1:20 pm    Post subject: Reply with quote

Thank you for responding so quickly.
Yes, it was done.

Two questions:
1- What is this function:
Code:
if form then form.Destroy() end -- Do not multiply the same sample!


2- This code is an example of the original code and the number of my panels and buttons are many. that's mean
Code:

buttonYes.OnClick = He
buttonNo.OnClick = Hea

put at the bottom of my code?
Back to top
View user's profile Send private message
AylinCE
Grandmaster Cheater Supreme
Reputation: 33

Joined: 16 Feb 2017
Posts: 1316

PostPosted: Sun Apr 14, 2024 1:52 pm    Post subject: Reply with quote

Code:
 if form then form.Destroy() end -- Do not multiply the same sample!
form = createForm(MainForm) -- The testing phase is; MainForm else createForm() sufficient.


form.Caption = 'test'
form.Height = 380
form.Width = 514

-------------------------------------------
local myText = createEdit(form)
myText.ReadOnly = true
myText.Color =  0xF0000
myText.Font.Size = 11
myText.Font.Color = 0x00FFFF
myText.Height = 8
myText.Width = 300
myText.Top = 4
myText.Left = 100
myText.Text = " WELLCOME "

--------------------------------------------------------

local CEPanel1 = createPanel(form) --
CEPanel1.Font.Size = 14
CEPanel1.Font.Color = 0x0FFF00
CEPanel1.Font.Bold = true
CEPanel1.Caption = 'please click'

CEPanel1.Alignment="taLeftJustify"
CEPanel1.Top = 33
CEPanel1.Left = 30
CEPanel1.Height = 40
CEPanel1.Width = 220

local buttonYes = createButton(CEPanel1)
buttonYes.Caption = 'ON'
buttonYes.Height = 24
buttonYes.Left = 110
buttonYes.Top = 8
buttonYes.Width = 48

local buttonNo = createButton(CEPanel1)
buttonNo.Caption = 'OFF'
buttonNo.Height = 24
buttonNo.Left = 165
buttonNo.Top = 8
buttonNo.Width = 48

---------------------------------------------------------

local CEPanel2 = createPanel(form) --
CEPanel2.Font.Size = 14
CEPanel2.Font.Color = 0x0FFF00
CEPanel2.Font.Bold = true
CEPanel2.Caption = 'please click'

CEPanel2.Alignment="taLeftJustify"
CEPanel2.Top = 80
CEPanel2.Left = 30
CEPanel2.Height = 40
CEPanel2.Width = 220

local buttonYes1 = createButton(CEPanel2)
buttonYes1.Caption = 'ON'
buttonYes1.Height = 24
buttonYes1.Left = 110
buttonYes1.Top = 8
buttonYes1.Width = 48

local buttonNo1 = createButton(CEPanel2)
buttonNo1.Caption = 'OFF'
buttonNo1.Height = 24
buttonNo1.Left = 165
buttonNo1.Top = 8
buttonNo1.Width = 48

   function He()
   showMessage("Activad")
   end

   function Hea()
   showMessage(" Disabled")
   end

   function He1()
   showMessage("Activad")
   end

   function Hea1()
   showMessage(" Disabled")
   end

buttonYes.OnClick = He
buttonNo.OnClick = Hea
buttonYes1.OnClick = He1 -- or He
buttonNo1.OnClick = Hea1 -- or Hea


Instead of constantly creating the same form over and over again during the code creation or form testing phase, this code allows you to destroy the previous form.

Code:
 if form then form.Destroy() end


I gave an example above for your 2nd question.
And yes, for function assignment, first generate the function, then assign a control (Button, CheckBox, etc.) to that function.

-------------------------------------------------------------------
I also added 2 more features in the code above.

1) "Owner", if you are going to put a button in the panel, the owner can be the panel, not the form.
Code:
local buttonYes = createButton(CEPanel1)

Thus, when the panel is hidden (CEPanel.Visible=false), the buttons are also hidden.
Also, instead of writing 3 hiding codes, you just need to hide the panel.

2) Instead of leaving spaces in the panel description (please click), "Alignment="taLeftJustify"" will reset the description.
The panel default legend alignment is "taCenter".

_________________
Hi Hitler Different Trainer forms for you!
https://forum.cheatengine.org/viewtopic.php?t=619279
Enthusiastic people: Always one step ahead
Do not underestimate me Master: You were a beginner in the past
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Sol.gaming
How do I cheat?
Reputation: 0

Joined: 14 Apr 2024
Posts: 9

PostPosted: Sun Apr 14, 2024 2:55 pm    Post subject: Reply with quote

The problem is completely solved
And one more question:
CT file and CETRAINER run well and all MODE MENU items work
But when the same program is saved as EXE in lua script:cheat tabel, the code does not perform the activities.
The main form opens. Items work.
But
The main activity, which is the same as AOBRep(searchV,replaceV)
is not working

Of course, I feel that although the process id is defined in the code, the problem is in inserting the progay (maybe)

But it is interesting that one of these two activities is not done.

I wanted to send you the code privately (due to copyright) for you to view, but unfortunately it was not possible because I am a new user.


Thank you for taking the time to do this Wink
Back to top
View user's profile Send private message
AylinCE
Grandmaster Cheater Supreme
Reputation: 33

Joined: 16 Feb 2017
Posts: 1316

PostPosted: Sun Apr 14, 2024 3:06 pm    Post subject: Reply with quote

I don't remember encountering this problem.
I have been using cetrainer instead of exe for a long time.
I think there may be other reasons for this.

But superficially my opinion is;
It's probably because the selected process has bits that don't overlap with the exe.

I recommend you to test the same codes with 32 and 64 bit Trainer.exe outputs.

_________________
Hi Hitler Different Trainer forms for you!
https://forum.cheatengine.org/viewtopic.php?t=619279
Enthusiastic people: Always one step ahead
Do not underestimate me Master: You were a beginner in the past
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Sol.gaming
How do I cheat?
Reputation: 0

Joined: 14 Apr 2024
Posts: 9

PostPosted: Sun Apr 14, 2024 3:15 pm    Post subject: Reply with quote

I tried with both 64 and 32 formats. But the problem remains.
Of course, the EXE and CETRAINER methods are the same because both ways can be accessed to the main code. Because in this part of the cheat engine software, it is not working well (the ct file related to the exe output and CETRAINER is created for a few seconds during the execution of the program in ..... and can be hacked. But the EXE output is CETRAINER is easier and there is no need to directly open the cheat engine.

When exporting EXE except for 32 and 64 format
Is there any special adjustment to be made?
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