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 


Improvement suggestion

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine
View previous topic :: View next topic  
Author Message
Fresco
Grandmaster Cheater
Reputation: 4

Joined: 07 Nov 2010
Posts: 600

PostPosted: Sun Feb 01, 2015 2:00 pm    Post subject: Improvement suggestion Reply with quote

Since I usually use very complex coding in the auto assembler, I find myself having to declare all labels using "label(labelname)" It is very confusing having to declare them all.

My suggestion is to remove the necessity to declare labels in the auto assembler, but still leave features such as registersymbol(labelname)
That is if it is possible.

Thank You!

_________________
... Fresco
Back to top
View user's profile Send private message
STN
I post too much
Reputation: 43

Joined: 09 Nov 2005
Posts: 2676

PostPosted: Mon Feb 02, 2015 4:52 am    Post subject: Reply with quote

+1 I agree. It gets tiring indeed when making tons of options or writing a lengthy script.

Alternatively, if that is not possible, being able to define a lot of labels at once would be nice. Something like this
label(label1, label2, labeln...)

_________________
Cheat Requests/Tables- Fearless Cheat Engine
https://fearlessrevolution.com
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

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

PostPosted: Mon Feb 02, 2015 5:05 am    Post subject: Reply with quote

I may be able to add it, but script execution may slow down then because it will only be able to determine it's a label after having parsed the whole script, and then it has to start over again

For those that don't want to wait and implement it themself, look into registerAutoAssemblerPrologue and use it to parse the script for missing label definitions and add them (keep in mind not to insert a label for alloc, define, aobscan, aobscanmodule, symbols or registered symbols)

_________________
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
zm0d
Master Cheater
Reputation: 7

Joined: 06 Nov 2013
Posts: 423

PostPosted: Mon Feb 02, 2015 5:29 am    Post subject: Reply with quote

Quote:
I may be able to add it, but script execution may slow down then because it will only be able to determine it's a label after having parsed the whole script, and then it has to start over again


I'm not in this AA executing handling, but why wouldn't you be able to automatically register these labels, once you determine them? So the "over again" part could be that fast as if you register labels on your own.
Back to top
View user's profile Send private message
++METHOS
I post too much
Reputation: 92

Joined: 29 Oct 2010
Posts: 4197

PostPosted: Mon Feb 02, 2015 5:40 am    Post subject: Reply with quote

Would that still be the case if the labels were defined automatically, anytime registersymbol was used? Essentially, you would just be combining two functions in to one, right? For example:

Code:
registersymbol.label(example)


Mr. Green even better:

Code:
rs(example)


If this could be done, you might also consider automatically setting unregistersymbol on deactivation of script so it does not have to be added. Although...that might slow it down some.
Back to top
View user's profile Send private message
Fresco
Grandmaster Cheater
Reputation: 4

Joined: 07 Nov 2010
Posts: 600

PostPosted: Thu Feb 05, 2015 7:20 pm    Post subject: Reply with quote

Maybe it's too much asking or daring, but I'm going to suggest another improvement anyway.

You could have the Auto Assembler dynamically calculate the size ( in bytes ) of each instructions as (the instructions) are written.
So that, when creating a loop we can write something like
Code:
1 //bla bla
2 inc ecx
3 cmp ecx, whateverNumber
4 je (+bytes) // + number of bytes that "jmp (-bytes)" at line 5 take (so this would jump at label at line 6)
5 jmp (-bytes) // - number (sum) of bytes that operands from line 1 to 4 take (so it would jump at label at line 0 zero)


Maybe place the resulting bytes near the numbers that keep track of the lines of code like:
Code:
1 5 jmp addy
2 1 nop
3 2 xor eax, eax
4 1 push eax


Something like what Microsoft IntelliSense is doing.

I know it's asking much and it requires a lot coding as well as effort.

Thanks!

_________________
... Fresco
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

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

PostPosted: Thu Feb 05, 2015 7:30 pm    Post subject: Reply with quote

a lot of coding and effort to make scripts look ugly and hard to follow...
(and not to mention that ce might insert some random nops inbetween just for the fun of it)
anyhow you can use @@: labels and @f to reference to the next @@ label and @b to reference the previous one

_________________
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
SteveAndrew
Master Cheater
Reputation: 30

Joined: 02 Sep 2012
Posts: 323

PostPosted: Fri Feb 06, 2015 10:33 am    Post subject: Reply with quote

I second that! The result just wouldn't be worth it. The auto label / labelless support though sounds like a great feature! I hear that it's already implemented in the svn, I'll have to pull the latest version to find out Smile

How about an "invoke" where:
Code:

invoke kernel32.WriteFile,[Handle],Buffer,[BufferSize],BytesWritten,0


would expand into: (for 32-bit)
Code:

push 0
push BytesWritten
push [BufferSize]
push Buffer
push [Handle]
call kernel32.WriteFile


and: (for 64-bit) off the top of my head so might not be correct but it's close I think
Code:

mov rcx,[Handle]
mov rdx,Buffer
mov r8d,[BufferSize]
mov r9,BytesWritten
push 0
call kernel32.WriteFile


lol. Or maybe not...

But how about at least with the @@: instead of just @f and @b for forward or back, you could do the second/third/fourth forward and backward anonymous label..

Something like:
Code:

alloc(SuperAnonymousLabelSupport,1024)

SuperAnonymousLabelSupport:
xor rax,rax
mov rbx,1
mov rcx,2
mov rdx,3

@@:
test rax,rax
je @f
cmp rbx,1
je @f2
cmp rcx,2
je @f3
cmp rdx,3
je @f4

@@: //test rax,rax gets here
jmp exit

@@: //cmp rbx,1 gets here
jmp exit

@@: //cmp rcx,2 gets here
jmp exit

@@: //cmp rdx,3 gets here
exit:
jmp @b5 //jumps back to first anonymous label (5th anonymous label back from this point)



Or maybe not @f and @f2, @f3 but @f and @f+1, @f+2, etc... @b, @b+1, @b+2, etc... (actually that might get interpreted already as just using an offset so maybe just a number or letter after @f or @b)

Laughing It could be a fun feature! I think. Maybe... right?

_________________
Back to top
View user's profile Send private message
++METHOS
I post too much
Reputation: 92

Joined: 29 Oct 2010
Posts: 4197

PostPosted: Fri Feb 06, 2015 1:47 pm    Post subject: Reply with quote

Since we're talking about it, there are a lot of ways that the script builder can be improved on. A few examples, just off the top of my head:

Maybe something like this (or with auto-complete feature or hotkeys for common items):



Something like this for easily combining multiple scripts:



Back to top
View user's profile Send private message
++METHOS
I post too much
Reputation: 92

Joined: 29 Oct 2010
Posts: 4197

PostPosted: Sun Feb 08, 2015 8:32 am    Post subject: Reply with quote

Another feature that would be nice to have, would be having the ability to save these line groupings (maybe by right-clicking on the little arrow?) so that they are permanent, but can be edited and removed. I have some scripts that are pushing 2000 lines, and it can sometimes be an arduous task to sift through.

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 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