 |
Cheat Engine The Official Site of Cheat Engine
|
View previous topic :: View next topic |
Author |
Message |
24quant42 Cheater
Reputation: 0
Joined: 19 Apr 2023 Posts: 31
|
Posted: Thu Nov 09, 2023 1:00 pm Post subject: Error before click OK in script AA |
|
|
Hello, I get an error when I want to change the code created through AA.
There is an "Auto Assemble script" item in the list of cheats. If I click "Change script" I can change it, but if I accidentally click the "OK" button, which is in the middle, I get an error like in the screenshot.
And after that I can no longer open this element and correct the code, because I always get an error like in the screenshot.
What should I do DarkByte?
My code example:
{$lua}
[ENABLE]
-- lua code
[DISABLE]
-- lua code
AND Errror file:
File ExceptionAutoSave.CT
Code: |
<?xml version="1.0" encoding="utf-8"?>
<CheatTable CheatEngineTableVersion="45">
<CheatEntries>
<CheatEntry>
<ID>0</ID>
<Description>"Auto Assemble script"</Description>
<VariableType>Auto Assembler Script</VariableType>
<AssemblerScript>{$lua}
memscan = getCurrentMemscan()
function firstScan()
protectionflags = "+W-C"
memscan.firstScan(soExactValue, vtDouble, rtRounded,
"15", nil,
0, 0x7fffffffffff, protectionflags, fsmAligned, "4", false, false, false, false)
end
function nextScan()
memscan.nextScan(soExactValue, rtRounded,
"33", nil,
false, false, false, false,false)
end
[ENABLE]
if vkF11 then vkF11.destroy() end
vkF11=createHotkey(firstScan, {VK_F11})
if vkF12 then vkF12.destroy() end
vkF12=createHotkey(nextScan, {VK_F12})
[DISABLE]
if vkF11 then vkF11.destroy() end
if vkF12 then vkF12.destroy() end
</AssemblerScript>
</CheatEntry>
</CheatEntries>
<UserdefinedSymbols/>
</CheatTable>
|
Description: |
|
Filesize: |
25.95 KB |
Viewed: |
2446 Time(s) |

|
|
|
Back to top |
|
 |
AylinCE Grandmaster Cheater Supreme
Reputation: 37
Joined: 16 Feb 2017 Posts: 1516
|
Posted: Thu Nov 09, 2023 1:37 pm Post subject: |
|
|
Code: |
[ENABLE]
{$lua}
memscan = getCurrentMemscan()
function firstScan()
protectionflags = "+W-C"
memscan.firstScan(soExactValue, vtDouble, rtRounded,
"15", nil,
0, 0x7fffffffffff, protectionflags, fsmAligned, "4", false, false, false, false)
end
function nextScan()
memscan.nextScan(soExactValue, rtRounded,
"33", nil,
false, false, false, false,false)
end
//{$asm}
//[ENABLE]
{$lua}
if vkF11 then vkF11.destroy() end
vkF11=createHotkey(firstScan, {VK_F11})
if vkF12 then vkF12.destroy() end
vkF12=createHotkey(nextScan, {VK_F12})
{$asm}
[DISABLE]
{$lua}
if vkF11 then vkF11.destroy() end
if vkF12 then vkF12.destroy() end
|
_________________
|
|
Back to top |
|
 |
ParkourPenguin I post too much
Reputation: 152
Joined: 06 Jul 2014 Posts: 4696
|
Posted: Thu Nov 09, 2023 2:22 pm Post subject: |
|
|
Missing `if syntaxcheck then return end`
Not setting destroyed objects to nil (they get destroyed twice- very bad)
_________________
I don't know where I'm going, but I'll figure it out when I get there. |
|
Back to top |
|
 |
24quant42 Cheater
Reputation: 0
Joined: 19 Apr 2023 Posts: 31
|
Posted: Thu Nov 09, 2023 11:10 pm Post subject: |
|
|
AylinCE wrote: | Code: |
[ENABLE]
{$lua}
if vkF12 then vkF12.destroy() end
|
|
Still, after clicking OK I get an error and can no longer change the code.
----------
When I click on the script in the list of cheats, I also get the following error.
The most interesting thing is that if you open AA and click New Window, then while a new AA window is open, and click on the script, then everything works and I can change the code.
But as soon as you close the new AA window, the error appears again. Apparently, after opening the AA windows and closing them, the CE code does not clear the object or component.... So CE cannot normally open the script in the AA window for editing
Description: |
|
Filesize: |
17.33 KB |
Viewed: |
2339 Time(s) |

|
|
|
Back to top |
|
 |
AylinCE Grandmaster Cheater Supreme
Reputation: 37
Joined: 16 Feb 2017 Posts: 1516
|
Posted: Fri Nov 10, 2023 6:13 am Post subject: |
|
|
1)
Code: | [ENABLE]
{$lua}
if syntaxcheck then return end
memscan = getCurrentMemscan()
|
2) No key tablet ..
Code: | if vkF11 then vkF11.destroy() end
vkF11=createHotkey(firstScan, {VK_F11})
if vkF12 then vkF12.destroy() end
vkF12=createHotkey(nextScan, {VK_F12})
|
Use;
Code: | if vkF11 then vkF11.destroy() vkF11=nil end
if vkF12 then vkF12.destroy() vkF12=nil end
vkF11=createHotkey(firstScan, VK_F11)
vkF12=createHotkey(nextScan, VK_F12)
|
_________________
|
|
Back to top |
|
 |
24quant42 Cheater
Reputation: 0
Joined: 19 Apr 2023 Posts: 31
|
Posted: Fri Nov 10, 2023 9:07 am Post subject: |
|
|
AylinCE wrote: | 1)
Code: | [ENABLE]
{$lua}
if syntaxcheck then return end
|
|
Thank you very much)) the errors are gone, everything works now.
Please tell me, does CE have a discord? I'd like to subscribe.
And yes, this topic can be closed, the problem is solved =)
|
|
Back to top |
|
 |
AylinCE Grandmaster Cheater Supreme
Reputation: 37
Joined: 16 Feb 2017 Posts: 1516
|
|
Back to top |
|
 |
|
|
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
|
|