Curt_09
Also known as Chozo
- 557
- Posts
- 16
- Years
- New Jersey
- Seen Oct 20, 2024
It isn't helping:
Now It does tottaly nothing but nothing. However It did glitch up one of the clouds.
However, It does really weird things when I revised the script after compiling :
Spoiler:'---------------
#org 0x900403
lock
checkflag 0x74
if 0x0 goto 0x890044F
if 0x1 goto 0x8900416
release
end
'---------------
#org 0x90044F
lock
loadpointer 0x0 0x8742B6A '""
if 0x0 goto 0xAC90049E
setdooropened 0x65AC 0x90AC
setdooropened 0xAC6C 0x6AFF
checkflag 0x143A
if 0x0 goto 0x8900478
if 0x1 goto 0x890049B
release
end
'---------------
#org 0x900416
lock
checkflag 0x143A
if 0x0 goto 0x8900429
if 0x1 goto 0x890044C
release
end
'---------------
#org 0x900478
lock
showsprite 0x7
msgbox 0x89004AA MSG_NORMAL '"???'?\h90?\h6C?"
trainerbattle 0x0 0x1D 0x0 0x89004E8 0x89004F1
hidesprite 0x7
setflag 0x143A
release
setdooropened 0x6CFF 0xFF02
lock
loadpointer 0x0 0x74AC6A
setdooropened 0xED00 0x90AC
setdooropened 0xACAC 0xACB4
givemoney 0xFFAC6CAC 0x6A
checkflag 0x143A
if 0x0 goto 0x89004C7
if 0x1 goto 0x89004EA
release
end
'---------------
#org 0x90049B
release
end
'---------------
#org 0x900429
lock
showsprite 0x7
msgbox 0x890045B MSG_NORMAL '"???\h65?\h90?\h6C?"
trainerbattle 0x0 0x1D 0x0 0x8900499 0x89004A2
hidesprite 0x7
setflag 0x143A
release
end
'---------------
#org 0x90044C
release
end
'---------------
#org 0x9004C7
lock
showsprite 0x7
msgbox 0x89004F9 MSG_NORMAL '"Huh?/nWhat's going on?/lWhat is th..."
trainerbattle 0x0 0x1D 0x0 0x8900537 0x8900540
hidesprite 0x7
setflag 0x143A
release
setdooropened 0x6CFF 0xFF02
lock
loadpointer 0x0 0xAC90AC49
setdooropened 0x6CAC 0xFFAC
updatecoins 0xE9 0xDC
setdooropened 0xE2BA 0xDCD1
'---------------
#org 0x9004EA
release
end
'---------
' Strings
'---------
#org 0x742B6A
=
#org 0x9004AA
= ???'?\h90?\h6C?
#org 0x9004E8
= ?
#org 0x9004F1
= ?\h90???\h6C?
#org 0x90045B
= ???\h65?\h90?\h6C?
#org 0x900499
= ?
#org 0x9004A2
= ?\h74 ? y?\h90???'?\h90?\h6C?
#org 0x9004F9
= Huh?/nWhat's going on?/lWhat is this cloud?/p.../p.../pHuh?!
#org 0x900537
= Gwwaah!
#org 0x900540
= Ughh...
Some strings came out of nowhere, and where did give money come from XD?
I hope you can help. :chu:
The future of the Dark Clone Mythology depends on you~
Dawn, Clint, Elvyan and Luke~ Team NatureKeeper
Revising a script after compiling can cause some major problems and make funky things happen. This is because when you compile XSE writes it to the ROM, and when you try to make major changes that take up more space originally used by the script, it overwrites things that have already been written to. Say, for example, we had this:
Spoiler:
#org @start
msgbox @1 0x2
end
#org @1
= Hey man.
msgbox @1 0x2
end
#org @1
= Hey man.
XSE writes the @start, then right after it on the lines of hex it writes the @1.
Hex looks something like this:
AF 01 0D 23 54 60 60 87 9B
Msgbox takes eight byes of space. Then our text takes up more bytes.
00 00 00 00 00 00
Now say we were to add to the already compiled script:
Spoiler:
#org 0x800000
msgbox 0x8800009 MSG_FACE
applymovement 0x1 @1
waitmovement 0x1
end
msgbox 0x8800009 MSG_FACE
applymovement 0x1 @1
waitmovement 0x1
end
Then it takes up more space that originally, but it has nowhere to put it. So it tries to overwrite the text, but it's already written and has a pointer to it...
So you end up with jumbled garbage like yours.
Simple solution: Make the necessary changes and just compile it at a new offset.
Or, even better: It you have foresight and know you're bound to mess up, you'll have made a backup copy of your hacked ROM. Just copy it over the one you messed up and try inserting it again.
Note: You can make changes to an already compiled script that take up less space, or simply change something (like changing applymovement 0x1 to applymovement 0x2.)