Re: Epic GTA2 Script Decompiler (AKA SCR Decompiler)
Posted: 26 Sep 2013, 09:12
Does your decompiler decompiles WHILE_EXEC ENDWHILE commands?
Do you know what these means: S_PLUS_S, S_MINUS_I, i know they are operators but whats the I and S?
Integer and String?
I did my own small mini decompiler few months ago, just very small, yesterday i was in a mood to decompile WHILE_EXEC ENDWHILE commands but its not complete because of these S_MINUS_I etc things. But it was alot easier to write new one from scratch than integrate something into C++ code of yours. I did it in Delphi. It decompiles simple WHILE_EXEC ENDWHILE loops. Also "++" and "--" for correct variables.
I added other commands as needed for my small test scripts. I only focused atm on loops and IF_ENDIFs.
By writing my own code i know how all works and how i could make different things.
Again, i repeat: im focused on loops and IF_ENDIFs. Nothing fancy, so its small and clean. For very specific tasks only.
Must finish that before trying IF_ENDIF. Especially nested things.
WHILE_EXEC could be also nested?
I must understand whats the difference between the S and I
Edit!
For ex. my simple script:
It used ID: 86 which is "S_LESS_I"
"loop" is string in his own way, but what difference it makes to miss2?
Its just variable.
I dont get it.
TM or anybody, do you have a complete list what kind of types and operators can be used to compare/add/ divide different things? Are they all documented correctly in dma docs?
Do you know what these means: S_PLUS_S, S_MINUS_I, i know they are operators but whats the I and S?
Integer and String?
I did my own small mini decompiler few months ago, just very small, yesterday i was in a mood to decompile WHILE_EXEC ENDWHILE commands but its not complete because of these S_MINUS_I etc things. But it was alot easier to write new one from scratch than integrate something into C++ code of yours. I did it in Delphi. It decompiles simple WHILE_EXEC ENDWHILE loops. Also "++" and "--" for correct variables.
I added other commands as needed for my small test scripts. I only focused atm on loops and IF_ENDIFs.
By writing my own code i know how all works and how i could make different things.
Again, i repeat: im focused on loops and IF_ENDIFs. Nothing fancy, so its small and clean. For very specific tasks only.
Must finish that before trying IF_ENDIF. Especially nested things.
WHILE_EXEC could be also nested?
I must understand whats the difference between the S and I
Edit!
For ex. my simple script:
Code: Select all
PLAYER_PED player = (49.5, 46.5, 1.0) 25 0
COUNTER loop = 321
LEVELSTART
WHILE_EXEC ( loop< 5621 )
do_nowt
endwhile
LEVELEND
"loop" is string in his own way, but what difference it makes to miss2?
Its just variable.
I dont get it.
TM or anybody, do you have a complete list what kind of types and operators can be used to compare/add/ divide different things? Are they all documented correctly in dma docs?