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 


Some kind of error

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
Razi
Expert Cheater
Reputation: 1

Joined: 17 Jan 2018
Posts: 205

PostPosted: Thu May 30, 2019 5:14 am    Post subject: Some kind of error Reply with quote

When I run the following script and try to open the file by clicking on the menu item, CE shows an error: Error:TControl.ChangeBounds loop detected :TCheckBox Left=0,Top=1000,Width=120,Height=17 NewLeft=0,NewTop=1001,NewWidth=120,NewHeight=17
Code:
UDF1.MenuItem3.OnClick = function()
load_dialog = createOpenDialog(self)
load_dialog.InitalDir = os.getenv('%USERPROFILE%')
load_dialog.Filter = '.MNU (*.MNU)|*.MNU|Exe files (*.exe)|*.EXE|All files (*.*)|*'
load_dialog.execute()
local path = load_dialog.FileName
openFileAsProcess(path, r)
end

Where is the mistake and why CE shows an error?
Back to top
View user's profile Send private message
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1668

PostPosted: Thu May 30, 2019 6:46 am    Post subject: Reply with quote

The error pop-up is not CE bug, it's Lazarus bug. It happened on CE Version 6.6

Are you using a Mac? If yes then you need to modify 'wine wincfg, to set a registry key to 0 (disable) or 1 (enable).

If not, try setting your form auto size to false.
add to the top of the script table: UDF1.AutoSize = false and if the form has a panel then try to set panel align as 'alClient'.

_________________
Stealing Code From Stolen Code...
And Admit It.. Hmmm....Typically LOL
Back to top
View user's profile Send private message
Razi
Expert Cheater
Reputation: 1

Joined: 17 Jan 2018
Posts: 205

PostPosted: Thu May 30, 2019 8:59 am    Post subject: Reply with quote

Corroder wrote:

Are you using a Mac?

I'm using Windows XP sp3

Quote:
If not, try setting your form auto size to false.
add to the top of the script table: UDF1.AutoSize = false and if the form has a panel then try to set panel align as 'alClient'.

Did it, but did not help.
Back to top
View user's profile Send private message
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1668

PostPosted: Thu May 30, 2019 9:03 am    Post subject: Reply with quote

Try to use CE 6.7 or 6.8
_________________
Stealing Code From Stolen Code...
And Admit It.. Hmmm....Typically LOL
Back to top
View user's profile Send private message
Razi
Expert Cheater
Reputation: 1

Joined: 17 Jan 2018
Posts: 205

PostPosted: Thu May 30, 2019 10:01 am    Post subject: Reply with quote

Corroder wrote:
Try to use CE 6.7 or 6.8

Yes, used CE 6.7 and 6.8.3, but it shows an error. Perhaps this error because of windows XP.
Back to top
View user's profile Send private message
AylinCE
Grandmaster Cheater Supreme
Reputation: 37

Joined: 16 Feb 2017
Posts: 1524

PostPosted: Thu May 30, 2019 10:38 am    Post subject: Re: Some kind of error Reply with quote

Razi wrote:
CE shows an error: Error:TControl.ChangeBounds loop detected :TCheckBox Left=0,Top=1000,Width=120,Height=17 NewLeft=0,NewTop=1001,NewWidth=120,NewHeight=17



I insist here. Smile
Write the script code for the above error here.
Is there a definition for "New"?
Rather than WinXP, perhaps the error is in the command. Wink

_________________
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
Razi
Expert Cheater
Reputation: 1

Joined: 17 Jan 2018
Posts: 205

PostPosted: Thu May 30, 2019 11:10 am    Post subject: Re: Some kind of error Reply with quote

Aylin wrote:
Write the script code for the above error here.
Is there a definition for "New"?

Create form with menu items and use following code
Code:
UDF1.MenuItem3.OnClick = function()
load_dialog = createOpenDialog(self)
load_dialog.InitalDir = os.getenv('%USERPROFILE%')
load_dialog.Filter = '.MNU (*.MNU)|*.MNU|Exe files (*.exe)|*.EXE|All files (*.*)|*'
load_dialog.execute()
local path = load_dialog.FileName
openFileAsProcess(path, r)
end
Back to top
View user's profile Send private message
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1668

PostPosted: Thu May 30, 2019 12:08 pm    Post subject: Reply with quote

@Razi: check here

https://www.cheatengine.org/forum/viewtopic.php?t=604133&sid=54feaf064a93813d762fb3fc1a98747e
https://forum.cheatengine.org/viewtopic.php?t=608543&sid=494323df0c139e1788650e61fed08aa1
https://forum.lazarus.freepascal.org/index.php?topic=10141.0
https://forum.cheatengine.org/viewtopic.php?p=5700886

So, if you insist on using CE 6.6 then follow the steps like show at link no.1 above

CE Source - MainUnit.pas near line 2675 replace:

from:
Code:
cbsaferPhysicalMemory:=tcheckbox.create(self);
cbsaferPhysicalMemory.Caption:=strSaferPhysicalMemory;
cbsaferPhysicalMemory.Checked:=dbk32functions.saferQueryPhysicalMemory;
cbsaferPhysicalMemory.Parent:=cbPauseWhileScanning.Parent;
cbsaferPhysicalMemory.left:=cbPauseWhileScanning.left;
cbsaferPhysicalMemory.Top:=cbPauseWhileScanning.top;
cbsaferPhysicalMemory.OnChange:=cbSaferPhysicalMemoryChange;   


to:
Code:
cbsaferPhysicalMemory:=tcheckbox.create(self);
cbsaferPhysicalMemory.Caption:=strSaferPhysicalMemory;
cbsaferPhysicalMemory.Checked:=dbk32functions.saferQueryPhysicalMemory;
cbsaferPhysicalMemory.Left:=cbPauseWhileScanning.Left;
cbsaferPhysicalMemory.Top:=cbPauseWhileScanning.Top;
cbsaferPhysicalMemory.OnChange:=cbSaferPhysicalMemoryChange;

//Fix for the changebounds bug: add the 8 lines below before setting parent
//Also setting parent after setting top & left avoids many ChangeBounds calls.
cbsaferPhysicalMemory.AnchorSideLeft.Control:=cbPauseWhileScanning.AnchorSideLeft.Control;
cbsaferPhysicalMemory.AnchorSideLeft.Side:=cbPauseWhileScanning.AnchorSideLeft.Side;
cbsaferPhysicalMemory.AnchorSideTop.Control:=cbPauseWhileScanning.AnchorSideTop.Control;
cbsaferPhysicalMemory.AnchorSideTop.Side:=cbPauseWhileScanning.AnchorSideTop.Side;
cbsaferPhysicalMemory.AnchorSideRight.Control:=cbPauseWhileScanning.AnchorSideRight.Control;
cbsaferPhysicalMemory.AnchorSideRight.Side:=cbPauseWhileScanning.AnchorSideRight.Side;
cbsaferPhysicalMemory.AnchorSideBottom.Control:=cbPauseWhileScanning.AnchorSideBottom.Control;
cbsaferPhysicalMemory.AnchorSideBottom.Side:=cbPauseWhileScanning.AnchorSideBottom.Side;
cbsaferPhysicalMemory.Parent:=cbPauseWhileScanning.Parent;


Then you need recompile CE source code.
The error doesn't exist on my machine when trying to open MNU or form as you created.
I use Win 7 ultimate 64bit and CE 6.8.3

_________________
Stealing Code From Stolen Code...
And Admit It.. Hmmm....Typically LOL
Back to top
View user's profile Send private message
AylinCE
Grandmaster Cheater Supreme
Reputation: 37

Joined: 16 Feb 2017
Posts: 1524

PostPosted: Thu May 30, 2019 4:32 pm    Post subject: Re: Some kind of error Reply with quote

Razi wrote:
Aylin wrote:
Write the script code for the above error here.
Is there a definition for "New"?

Create form with menu items and use following code
Code:
UDF1.MenuItem3.OnClick = function()
load_dialog = createOpenDialog(self)
load_dialog.InitalDir = os.getenv('%USERPROFILE%')
load_dialog.Filter = '.MNU (*.MNU)|*.MNU|Exe files (*.exe)|*.EXE|All files (*.*)|*'
load_dialog.execute()
local path = load_dialog.FileName
openFileAsProcess(path, r)
end




_________________
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
Razi
Expert Cheater
Reputation: 1

Joined: 17 Jan 2018
Posts: 205

PostPosted: Fri May 31, 2019 3:25 am    Post subject: Reply with quote

Corroder wrote:
@Razi: check here
So, if you insist on using CE 6.6 then follow the steps like show at link no.1 above

CE Source - MainUnit.pas near line 2675 replace:

from:
Code:
cbsaferPhysicalMemory:=tcheckbox.create(self);
cbsaferPhysicalMemory.Caption:=strSaferPhysicalMemory;
cbsaferPhysicalMemory.Checked:=dbk32functions.saferQueryPhysicalMemory;
cbsaferPhysicalMemory.Parent:=cbPauseWhileScanning.Parent;
cbsaferPhysicalMemory.left:=cbPauseWhileScanning.left;
cbsaferPhysicalMemory.Top:=cbPauseWhileScanning.top;
cbsaferPhysicalMemory.OnChange:=cbSaferPhysicalMemoryChange;   


to:
Code:
cbsaferPhysicalMemory:=tcheckbox.create(self);
cbsaferPhysicalMemory.Caption:=strSaferPhysicalMemory;
cbsaferPhysicalMemory.Checked:=dbk32functions.saferQueryPhysicalMemory;
cbsaferPhysicalMemory.Left:=cbPauseWhileScanning.Left;
cbsaferPhysicalMemory.Top:=cbPauseWhileScanning.Top;
cbsaferPhysicalMemory.OnChange:=cbSaferPhysicalMemoryChange;

//Fix for the changebounds bug: add the 8 lines below before setting parent
//Also setting parent after setting top & left avoids many ChangeBounds calls.
cbsaferPhysicalMemory.AnchorSideLeft.Control:=cbPauseWhileScanning.AnchorSideLeft.Control;
cbsaferPhysicalMemory.AnchorSideLeft.Side:=cbPauseWhileScanning.AnchorSideLeft.Side;
cbsaferPhysicalMemory.AnchorSideTop.Control:=cbPauseWhileScanning.AnchorSideTop.Control;
cbsaferPhysicalMemory.AnchorSideTop.Side:=cbPauseWhileScanning.AnchorSideTop.Side;
cbsaferPhysicalMemory.AnchorSideRight.Control:=cbPauseWhileScanning.AnchorSideRight.Control;
cbsaferPhysicalMemory.AnchorSideRight.Side:=cbPauseWhileScanning.AnchorSideRight.Side;
cbsaferPhysicalMemory.AnchorSideBottom.Control:=cbPauseWhileScanning.AnchorSideBottom.Control;
cbsaferPhysicalMemory.AnchorSideBottom.Side:=cbPauseWhileScanning.AnchorSideBottom.Side;
cbsaferPhysicalMemory.Parent:=cbPauseWhileScanning.Parent;


Then you need recompile CE source code.
The error doesn't exist on my machine when trying to open MNU or form as you created.
I use Win 7 ultimate 64bit and CE 6.8.3


I'm using CE 6.7 and CE 6.8.3. Lazarus downloaded and installed, but didn't find on the forum what to do next.
Quote:
C) Compiling and Running.

1) Open Lazarus from start menu
2) Project-> Open Project
3) Browse to the folder where you downloaded source files
4) go to Cheat engine source folder
5) Select cheatengine.lpi
6) Run-> Build or (Shift+F9)
7) F9

then MainUnit.pas from folder: CE source\cheat-engine\trunk\Cheat Engine was changed, then what to do next, just press ctrl+F9 or shift+F9 to compile project? But lazarus shows error: Error: ppcx64.exe can't be executed, error message: Failed to execute ""ppcx64.exe" -Twin64 -MObjFPC -Scghi -O1 -g -gl -l -vewnhibq -FuI:\lazarus\packager\registration\ -FUI:\lazarus\packager\units\x86_64-win64\ fcllaz.pas
I'm using windows XP sp3 (32 bit).
Back to top
View user's profile Send private message
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1668

PostPosted: Fri May 31, 2019 5:12 am    Post subject: Reply with quote

Download and install Lazarus version 2.0.0

Run Lazarus and click on Project->Open Project. Select cheatengine.lpi from the Cheat Engine folder as the project.

Click on Run->Build or use SHIFT+F9.

If you want to run or debug from the IDE on Windows you will need to start Lazarus as administrator.

_________________
Stealing Code From Stolen Code...
And Admit It.. Hmmm....Typically LOL
Back to top
View user's profile Send private message
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1668

PostPosted: Fri May 31, 2019 1:20 pm    Post subject: Reply with quote

I don't have recompiled CE and also I am not sure the problem will disappear since the problem seems comes from Windows XP environment.
Recompile CE source also need to define for 32bit or 64bit.
I am sure DB knows the solutions and help you.

_________________
Stealing Code From Stolen Code...
And Admit It.. Hmmm....Typically LOL
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

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

PostPosted: Fri May 31, 2019 1:38 pm    Post subject: Reply with quote

no idea.
_________________
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