View previous topic :: View next topic |
Author |
Message |
Fresco Grandmaster Cheater
Reputation: 4
Joined: 07 Nov 2010 Posts: 600
|
Posted: Sun Feb 01, 2015 2:00 pm Post subject: Improvement suggestion |
|
|
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 |
|
 |
STN I post too much
Reputation: 43
Joined: 09 Nov 2005 Posts: 2676
|
Posted: Mon Feb 02, 2015 4:52 am Post subject: |
|
|
+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...)
_________________
|
|
Back to top |
|
 |
Dark Byte Site Admin
Reputation: 470
Joined: 09 May 2003 Posts: 25796 Location: The netherlands
|
Posted: Mon Feb 02, 2015 5:05 am Post subject: |
|
|
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 |
|
 |
zm0d Master Cheater
Reputation: 7
Joined: 06 Nov 2013 Posts: 423
|
Posted: Mon Feb 02, 2015 5:29 am Post subject: |
|
|
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 |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Mon Feb 02, 2015 5:40 am Post subject: |
|
|
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) |
even better:
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 |
|
 |
Fresco Grandmaster Cheater
Reputation: 4
Joined: 07 Nov 2010 Posts: 600
|
Posted: Thu Feb 05, 2015 7:20 pm Post subject: |
|
|
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 |
|
 |
Dark Byte Site Admin
Reputation: 470
Joined: 09 May 2003 Posts: 25796 Location: The netherlands
|
Posted: Thu Feb 05, 2015 7:30 pm Post subject: |
|
|
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 |
|
 |
SteveAndrew Master Cheater
Reputation: 30
Joined: 02 Sep 2012 Posts: 323
|
Posted: Fri Feb 06, 2015 10:33 am Post subject: |
|
|
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
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)
It could be a fun feature! I think. Maybe... right?
_________________
|
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Fri Feb 06, 2015 1:47 pm Post subject: |
|
|
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 |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Sun Feb 08, 2015 8:32 am Post subject: |
|
|
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 |
|
 |
|