|
 |
|
|
|
|
|
GTA Modification Forums
[REL] Sanny Builder A newest SA Mission Editor
 |
|
 |
| |
Seemann  |
|
Ruhe

Group: Members
Joined: Sep 3, 2004



|
@spaceeinstein | QUOTE | | How come when I tried to decompile a modded SCM (like my All In One), there's an error that said "Unknown file header"? |
hmm. I don't know what is happened, but I'll try to fix this problem. | QUOTE | | Can you not make it automatic? |
OK. Output file will be deleted if decompilling fails. | QUOTE | | The find feature kind of sucked |  yeah, you are right. In future I will make new find feature, maybe like in Delphi. | QUOTE | | I was inserting a new mission when this thing told me to use @34 as max in threads. But this is a mission! |
Do you declared it as | CODE | | DEFINE MISSION <num> at @Label |
? Where do you insert it? After all missions or in the end of file? @random_download | QUOTE | Better would be to implement a system like in Point, where you can do:
|
But how can I know what type of variables is used: integer or float? so, there is can be two opcodes: | CODE | | 0084: $var = $var2 ;; integer values and handles |
| CODE | | 0086: $var = $var2 ;; floating-point values only |
do prompt every time when program found this, or add declaration section where you can set the type of variable, like | CODE | var $var : float $var2 : integer
|
? @superglitch I have no free time to make the multibrowsing site, that would be the same under all browsers. Maybe later... @Demarest | QUOTE | | Besides that, @33 is the maximum in threads. |
oops. my bad
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
Demarest  |
|
what could be

Group: BUSTED!
Joined: Jul 12, 2003

|
| QUOTE (Seemann @ Sep 4 2005, 08:12) | But how can I know what type of variables is used: integer or float? so, there is can be two opcodes:
| CODE | | 0084: $var = $var2;; integer values and handles |
| CODE | | 0086: $var = $var2;; floating-point values only | do prompt every time when program found this, or add declaration section where you can set the type of variable, like| CODE | var $var : float $var2 : integer | | That's really up to you. If you check out Barton's readme, he used a single letter to define integers, fixed strings, etc when in a situation where the compiler had no previous data to go off of. Personally, I never minded datatypes. They told the story every bit as much as say, using 0.0 instead of 0.
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
spaceeinstein  |
|
巧克力

Group: Members
Joined: Jul 17, 2003



|
| QUOTE (Seemann @ Sep 4 2005, 08:12) | | QUOTE | | I was inserting a new mission when this thing told me to use @34 as max in threads. But this is a mission! | Do you declared it as | CODE | | DEFINE MISSION <num> at @Label | ? Where do you insert it? After all missions or in the end of file? | I do know how to add missions successfully (Mod Shop).
DEFINE MISSION 134 AT @BUYPRO1 DEFINE MISSION 135 AT @R_MICH_2858 <---
:BUYPRO1_4285 00BE: text_clear_all 0373: set_camera_directly_behind_player 02EB: restore_camera_with_jumpcut 01B4: set_player $PLAYER_CHAR frozen_state 1 03BF: set_player $PLAYER_CHAR ignored_by_everyone_to 0 02A3: toggle_widescreen 0 0004: $ON_MISSION = 0 ;; integer values 01BD: $184 = current_time_in_ms 00D8: mission_cleanup 004E: end_thread 0051: return
;-------------Mission 135--------------- <----
:R_MICH_2858 <---- 0050: gosub @R_MICH_2874 <---- 0050: gosub @R_MICH_31509 <---- 004E: end_thread <----
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
Seemann  |
|
Ruhe

Group: Members
Joined: Sep 3, 2004



|
@spaceeinstein ok, I have solved first problem. It looks like SaMB had wrote your scm's header info incorrectly. | CODE | HOTDOG: Base = 3598795 Size = 725 AAA: Base = 0 Size = 8 CARDRIVER: Base = 8 Size = 17601 HELIDRIVER: Base = 17609 Size = 14118
|
Base is the start point in global script code where external script should be copied from script.img. AAA's base is always equal 0. MB should ignore this script and write correct base for next scripts: 3599520 for CARDRIVER and 3617121 for HELIDRIVER. But it doesn't. So, if you will define your scripts before AAA, like | CODE | DEFINE EXTERNAL_SCRIPT_NAME HOTDOG; 77 DEFINE EXTERNAL_SCRIPT_NAME CARDRIVER; 79 DEFINE EXTERNAL_SCRIPT_NAME HELIDRIVER; 80 DEFINE EXTERNAL_SCRIPT_NAME AAA; 78
|
and recompile in MB, it should be enough. Sanny will decompile such SCM without any problem. btw, in Sanny script 'AAA' does not occurred at all. Edit: About find feature. If you have checked 'Search from caret' it will search from cursor, not from beginning of the file. @superglitch & ZAZ Do you can not download rar archive from my site? Maybe problem in the hosting. I will try to mirror this file next time. This post has been edited by Seemann on Monday, Sep 5 2005, 05:05
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
Demarest  |
|
what could be

Group: BUSTED!
Joined: Jul 12, 2003

|
| QUOTE (Seemann @ Sep 5 2005, 02:28) | I've solved the second problem (with local's out of range in mission). Thank you for finding this bug. I am not sure about optional check. Anyway its ranges should be checked. I see in your All in One Mod (v.1.01) in threads 'INTROSL' and 'INTROSH' local variables with names above 900 are used. Do you want optional check because of them? | To me, it doesn't matter WHY. I myself am finding more limitations in Barton's work every day. The average user won't notice and won't know it, but for those trying to do less common acts, some things get in the way. If you kept the checking on by default, but allowed users to turn it off, everybody wins regardless of "why?".
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
spaceeinstein  |
|
巧克力

Group: Members
Joined: Jul 17, 2003



|
| QUOTE (Seemann @ Sep 5 2005, 02:28) | I see in your All in One Mod (v.1.01) in threads 'INTROSL' and 'INTROSH' local variables with names above 900 are used. Do you want optional check because of them? | Yes, but I can change it. That was the Driver Mod Pavel made. He made the locals extremely high. I didn't bother to edit it because it works fine with everyone.
EDIT: The builder decompiles some coordinates wrong. It makes some -2.5 to -2.49. It makes almost all -100.0 into -99.99. This post has been edited by spaceeinstein on Monday, Sep 5 2005, 16:15
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
Y_Less  |
|
629

Group: Members
Joined: Mar 14, 2004



|
Seeman: a few things we (Demarest and I) discovered the other day you may like (we may like you to ) include:
1) jumps accept any form of integer for their parameter (BWME can compile jumps using 1 byte integers (data type 04), but crashes on decompile.
2) variables in jumps, another thing BWME can compile but not decompile - although the way it doesn't decompile is very odd and I don't see how it can be a by-product, but meh, I'm speculating.
3) -1@ (local variable -1, exists but is unaccessible).
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
Demarest  |
|
what could be

Group: BUSTED!
Joined: Jul 12, 2003

|
| QUOTE (Y_Less @ Sep 5 2005, 13:21) | | 3) -1@ (local variable -1, exists but is unaccessible). | Inaccessible for reasons that I believe are beyond the reach of anything short of hacking the EXE.
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
Demarest  |
|
what could be

Group: BUSTED!
Joined: Jul 12, 2003

|
Well, the code we were working with was the code trap at the end off a stripped scm| CODE | :MAIN3 0001: wait 250& ms 0002: jump 12? |
That did not work because jumps in MAIN are absolute. However, in missions, jumps are negatively relative. So if you place that loop in a mission, it will jump 12 bytes backwards (Y_Less said 1 byte, but in this case, the integer 250 is 2 bytes and can be 4). Barton's Builder compiles the 12? above as a single byte, but the game will look for a 4 byte label. The game crashes. Y_Less used a hex editor to make the 12? take up 4 bytes and the code ran without issue. It would also be nice to be able to jump with a variable that would contain the bytes.
As far as decompiling, for whatever reason, Barton's Builder disregards the datatype and assumes it's a label. So the above code would decompile with jump X where X is the hex address it would assign to the label MAIN3. It would still work as intended, but would actually CHANGE code that was compiled and subsequently decompiled. Still, you can see that this would be unsatisfactory for variables. In fact, the variable being undefined left Mission Builder (still disregarding datatype) unsure of what to put there and just crashed.
I hope that answers your question and since Y_Less was the one doing the hexing, he will have to correct me if I've misrepresented anything we worked on. He knows more about this than I do
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
0 User(s) are reading this topic (0 Guests and 0 Anonymous Users)
0 Members:
Pages:
(27) 1 [2] 3 4 ... Last »
Track this topic
Receive email notification when a reply has been made to this topic and you are not active on the board.
Subscribe to this forum
Receive email notification when a new topic is posted in this forum and you are not active on the board.
Download / Print this Topic
Download this topic in different formats or view a printer friendly version.
| |
 |
|
 |
|
|
|
|