Jul 14, 2013 at 2:19 AM
The TideWalker
Modding Community Discord Founder
"That dog!"
Join Date: Apr 5, 2013
Location: In my mind and of my body.
Posts: 1640
Age: 26




Noxid said:
undo the changes?


the thing is I don't know what in the world I did. -_-








MagicDoors said:
You did make a backup, right?


yeah. . . but that would be in an old executable, the glitch has been around in my executable(s) for quite a while.



Well, it's not THAT bad though, just reprogramming framarects and re-applying some patches. (20 minutes of work at most)







AND SPEAKING OF


offset 004937F4
CPU Disasm
Address Hex dump Command Comments
004937F4 \8B0D D85A4A00 MOV ECX,DWORD PTR DS:[4A5AD8]
004937FA 030D E05A4A00 ADD ECX,DWORD PTR DS:[4A5AE0]
00493800 8079 01 54 CMP BYTE PTR DS:[ECX+1],54 ;T
00493804 ^ 0F85 2917F9FF JNE 00424F33 : if not T, go to next command.
0049380A 8079 02 58 CMP BYTE PTR DS:[ECX+2],58 ;X
0049380E ^ 0F85 1F17F9FF JNE 00424F33
00493814 8079 03 43 CMP BYTE PTR DS:[ECX+3],43 ;C
00493818 ^ 0F85 1517F9FF JNE 00424F33
0049381E 8B15 E05A4A00 MOV EDX,DWORD PTR DS:[4A5AE0]
00493824 83C2 04 ADD EDX,4
00493827 52 PUSH EDX :set script and such
00493828 E8 D3E0F8FF CALL 00421900
0049382D 83C4 04 ADD ESP,4
00493830 83F8 01 CMP EAX,1 ;see if argument is 1
00493833 74 11 JE SHORT 00493846
00493835 83F8 02 CMP EAX,2 ;see if argument is 2
00493838 74 18 JE SHORT 00493852
0049383A 83F8 03 CMP EAX,3 ;see if argument is 3
0049383D 74 1F JE SHORT 0049385E
0049383F 83F8 04 CMP EAX,4 ;see if argument is 4
00493842 74 26 JE SHORT 0049386A
00493844 EB 3C JMP SHORT 00493882 ;if not, unconditional jump
00493846 C705 AD534200 F MOV DWORD PTR DS:[4253AD],00FFFFFF argument is 1, store 00FFFFFF to the text color address
00493850 EB 3A JMP SHORT 0049388C
00493852 C705 AD534200 F MOV DWORD PTR DS:[4253AD],00FAEEFF argument is 2, store 00FAEEFF to the text color address
0049385C EB 2E JMP SHORT 0049388C
0049385E C705 AD534200 E MOV DWORD PTR DS:[4253AD],00FAEFEF argument is 3. . .
00493868 EB 22 JMP SHORT 0049388C
0049386A C705 AD534200 F MOV DWORD PTR DS:[4253AD],00FA33FF argument is 4. . .
00493874 EB 16 JMP SHORT 0049388C
00493876 C705 AD534200 F MOV DWORD PTR DS:[4253AD],00FEFFFF argument is none of them. . .
00493880 EB 0A JMP SHORT 0049388C
00493882 C705 6CE64900 F MOV DWORD PTR DS:[49E66C],00FFEEFF
0049388C C705 E05A4A00 0 MOV DWORD PTR DS:[4A5AE0],8
00493896 83C2 08 ADD EDX,8 <TXC commant is 8 digets. . . store to EDX
00493899 8915 E05A4A00 MOV DWORD PTR DS:[4A5AE0],EDX store script stuff. . .
0049389F ^ E9 031AF9FF JMP 004252A7 return to beginning of the parser.


can I, y'know, get some help with this?

 
Jul 15, 2013 at 4:52 PM
Senior Member
"I, Ikachan. The Life and Documentary of the OrigiNAL SQuiD."
Join Date: Nov 14, 2012
Location:
Posts: 167
How do I change the color of the CS font? And how do I change what the sounds sound like?
 
Jul 15, 2013 at 5:09 PM
The TideWalker
Modding Community Discord Founder
"That dog!"
Join Date: Apr 5, 2013
Location: In my mind and of my body.
Posts: 1640
Age: 26
fadoink said:
How do I change the color of the CS font? And how do I change what the sounds sound like?

Well, if you would have read the post above you would have know it is at address 4253AD

but the sound, I don't know that one.
 
Jul 15, 2013 at 9:21 PM
Based Member
"Life begins and ends with Nu."
Join Date: Dec 31, 2011
Location: United States
Posts: 2307
Age: 27
Jul 15, 2013 at 10:08 PM
Senior Member
"I, Ikachan. The Life and Documentary of the OrigiNAL SQuiD."
Join Date: Nov 14, 2012
Location:
Posts: 167
Now How do I import it into CS?
 
Jul 15, 2013 at 11:58 PM
Based Member
"Life begins and ends with Nu."
Join Date: Dec 31, 2011
Location: United States
Posts: 2307
Age: 27
Documentation on the program is provided in the download.
 
Jul 16, 2013 at 4:49 AM
The TideWalker
Modding Community Discord Founder
"That dog!"
Join Date: Apr 5, 2013
Location: In my mind and of my body.
Posts: 1640
Age: 26

Ok, So I'm trying to make a new TSC command, but the game keeps crashing every time I try and use it. (I'm using doukustu assembler, so you know)



here is is:
offset 004937F4

MOV ECX,DWORD PTR DS:[4A5AD8]
ADD ECX,DWORD PTR DS:[4A5AE0] ;set up Script Position and such.
CMP BYTE PTR DS:[EAX+1],54 ;T
JNE 00424F33 ;if letter isn't T, go to 424F33 (address of <GIT command)
CMP BYTE PTR DS:[EaX+2],58 ;X
JNE 00424F33 ;if letter isn't X, go to 424F33.
CMP BYTE PTR DS:[EAX+3],43 ;C
JNE 00424F33 ;if letter isn't C, go to 424F33.
MOV EDX,DWORD PTR DS:[4A5AE0] ;store Script Position to EDX
ADD EAX,4 ;Add 4 to Script Position
PUSH EAX ;Push the script position
CALL 00421900 ;CALL Ascii to number Function
ADD ESP,4 ;Fix the stack
MOV ECX,EAX ;Get argument from <TXC command and store it into EAX
CMP EAX,1 ;If 1st argument is 1, then store 00FFFFFF to Address [004253AD]
JE :color_1
CMP EAX 2 ;If 1st argument is 2, then store 00FAEEFF to Address [004253AD]
JE :color_2
CMP EAX 3 ;If 1st argument is 3, then store 00FAEFEF to Address [004253AD]
JE :color_3
CMP EAX 4 ;If 1st argument is 4, then store 00FA33FF to Address [004253AD]
JE :color_4


JMP :color_none

:color_1
MOV DWORD PTR DS:[004253AD], 00FFFFFF ;If 1st argument is 1, then store 00FFFFFF to Address [004253AD]
JMP :end


:color_2
MOV DWORD PTR DS:[004253AD], 00FAEEFF ;If 1st argument is 2, then store 00FAEEFF to Address [004253AD]
JMP :end


:color_3
MOV DWORD PTR DS:[004253AD], 00FAEFEF ;If 1st argument is 3, then store 00FAEEFF to Address [004253AD]
JMP :end


:color_4
MOV DWORD PTR DS:[004253AD], 00FA33FF ;If 1st argument is 4, then store 00FAEEFF to Address [004253AD]
JMP SHORT :end


:color_none
MOV DWORD PTR DS:[004253AD], 00FEFFFF ;If 1st argument is not any of these, then store 00FEFFFF to Address [004253AD]
JMP SHORT :end

:end
ADD ESP,8 ;Fix the stack
MOV EDX,DWORD PTR DS:[4A5AE0] ;Get script position
ADD EDX 8 ;add 8 to script position
MOV DWORD PTR DS:[4A5AE0],EDX ;Store Back to Script Position
JMP 004252A7 ;jump back to beginning of parser




I think that I'm doing something wrong at the end. :/



EDIT-



stupid spoiler tags won't work -_-
 
Jul 16, 2013 at 5:48 AM
Lvl 1
Forum Moderator
"Life begins and ends with Nu."
Join Date: May 28, 2008
Location: PMMM MMO
Posts: 3713
Age: 31
Ok so 2 things:

1. Debugging assembly is hard. This is why few people do it, and why fewer will help you with debugging your own code. Especially since it's hard to debug something you don't have direct access to. So don't be surprised if you don't get too much help with it. If you want to use black magic, you need to be prepared to suffer the consequences.

2. Ollydbg has this feature where you can run the executable WITHIN ollydbg, and then it will show you where it breaks in the ASM normally. Just load the exe and look for the little play button/icon.
 
Jul 16, 2013 at 6:00 AM
Senior Member
"I, Ikachan. The Life and Documentary of the OrigiNAL SQuiD."
Join Date: Nov 14, 2012
Location:
Posts: 167
I changed the font color green on accident :cool:
I want to chage it back to white. Does anyone have the codes I need?
 
Jul 16, 2013 at 2:11 PM
The TideWalker
Modding Community Discord Founder
"That dog!"
Join Date: Apr 5, 2013
Location: In my mind and of my body.
Posts: 1640
Age: 26
GIRakaCHEEZER said:
Ok so 2 things:

1. Debugging assembly is hard. This is why few people do it, and why fewer will help you with debugging your own code. Especially since it's hard to debug something you don't have direct access to. So don't be surprised if you don't get too much help with it. If you want to use black magic, you need to be prepared to suffer the consequences.

2. Ollydbg has this feature where you can run the executable WITHIN ollydbg, and then it will show you where it breaks in the ASM normally. Just load the exe and look for the little play button/icon.
Ok, I'll try that, thank you

fadoink said:
I changed the font color green on accident :cool:
I want to chage it back to white. Does anyone have the codes I need?
it's 00FEFFFF
 
Jul 16, 2013 at 6:49 PM
Junior Member
"Wahoo! Upgrade!"
Join Date: Jan 5, 2013
Location:
Posts: 45
Age: 29
Hello, sorry if I keep bugging you but,
i'm very new to assembly and have no idea on what i'm doing.
I tried following the tutorials on this site but I don't even understand them.

There is two hacks I want to apply,
The infinite mimiga mask
http://www.cavestory.org/forums/threads/3159/

and the Max health hack
http://www.cavestory.org/forums/threads/2047/

How do I apply these hacks? Do I just copy and paste the lines one by one or is there a different way of doing it? It's really confusing to me even
with the tutorials I tried to follow. So can someone give me a step by step instruction on how to apply these hacks? Or is that too much to ask?
I would just download the pre-patched versions but there is two problems, one is that the infinite mimiga mask pre-patched download link is broken
and two is that I want them together, if that's even possible. I will continue to try and patch the game myself with these hacks but I just wanted to know if anyone
can help me with it.
 
Jul 16, 2013 at 9:34 PM
Senior Member
"I, Ikachan. The Life and Documentary of the OrigiNAL SQuiD."
Join Date: Nov 14, 2012
Location:
Posts: 167
Bombchu Link said:
Ok, I'll try that, thank you


it's 00FEFFFF
It just turned red. 00FEFFFF turned red. Not all of it though...
 
Jul 21, 2013 at 3:38 AM
Based Member
"Life begins and ends with Nu."
Join Date: Dec 31, 2011
Location: United States
Posts: 2307
Age: 27
What's the best way of finding an NPC's code for when they die? I presume it would be somewhere where there's a command that has something like "CMP [E_X+40],0" that compared its health with zero and jumped to what ever makes it die, but I haven't found anything of the sort. The main NPC of interest in my case is the Sandcroc.
 
Jul 21, 2013 at 3:56 AM
Lvl 1
Forum Moderator
"Life begins and ends with Nu."
Join Date: May 28, 2008
Location: PMMM MMO
Posts: 3713
Age: 31
HaydenStudios said:
What's the best way of finding an NPC's code for when they die? I presume it would be somewhere where there's a command that has something like "CMP [E_X+40],0" that compared its health with zero and jumped to what ever makes it die, but I haven't found anything of the sort. The main NPC of interest in my case is the Sandcroc.
Most NPCs don't have such code, as it's handled externally by some other function I think. Gaudis and butes are the exceptions, but you'll notice how they have 1000 hp. What they do then is compare their hp to 985 or something like that for triggering the dropping of their corpse entities.
 
Jul 21, 2013 at 4:23 AM
Based Member
"Life begins and ends with Nu."
Join Date: Dec 31, 2011
Location: United States
Posts: 2307
Age: 27
Then how would I go about changing what happens when a certain NPC dies? Do you know the address for the function that handles this, or where I might find any documentation on it? I couldn't find any information on it in the assembly compendium.
 
Jul 21, 2013 at 4:38 AM
Lvl 1
Forum Moderator
"Life begins and ends with Nu."
Join Date: May 28, 2008
Location: PMMM MMO
Posts: 3713
Age: 31
HaydenStudios said:
Then how would I go about changing what happens when a certain NPC dies? Do you know the address for the function that handles this, or where I might find any documentation on it? I couldn't find any information on it in the assembly compendium.
I'd recommend doing it the way pixel does, that is setting their HP to something really high like 1000 and then checking for 1000-x hp in their AI.
 
Jul 23, 2013 at 4:51 PM
Senior Member
"I, Ikachan. The Life and Documentary of the OrigiNAL SQuiD."
Join Date: Nov 14, 2012
Location:
Posts: 167
I have a certain door script which is...

#0104
<PRI<SOU0011<HMC<MOV0033:0016<SMC<END

There is a problem in the game. I go to where I set it but I automatically get moved back. Can anyone help me or is this just 2x problem?
 
Jul 23, 2013 at 11:01 PM
scrungy
Bobomb says: "I need a hug!"
Join Date: Oct 7, 2011
Location: PrtWeed
Posts: 777
Age: 24
fadoink said:
I have a certain door script which is...

#0104
<PRI<SOU0011<HMC<MOV0033:0016<SMC<END

There is a problem in the game. I go to where I set it but I automatically get moved back. Can anyone help me or is this just 2x proble


Just do this

#0104

<KEY<MOV0033:0016<END



Much better
 
Jul 23, 2013 at 11:30 PM
The TideWalker
Modding Community Discord Founder
"That dog!"
Join Date: Apr 5, 2013
Location: In my mind and of my body.
Posts: 1640
Age: 26
Aar said:
Just do this

#0104

<KEY<MOV0033:0016<END



Much better


No.



The <SOU's and the <HMC/SMC are needed for the door sound and to make quote dissapear and are completely unrelated to the problem that he has except that he should use an actual <KEY instead of <PRI.



Some solutions:



#1 He has his <MOV's incorrect.



#2 Used <PRI instead of <KEY (I think that all entity's cannot move when <PRI is used even inside of a <MOV command)



#3 Use a <TRA instead.
 
Jul 23, 2013 at 11:44 PM
Based Member
"Life begins and ends with Nu."
Join Date: Dec 31, 2011
Location: United States
Posts: 2307
Age: 27
Bombchu Link said:
Used <PRI instead of <KEY (I think that all entity's cannot move when <PRI is used even inside of a <MOV command)
Just now tested this myself by changing the events of the doors in the hideout in CS to using <PRI, and they still work, aside from the doors not animating when this has been done.


Bombchu Link said:
Use a <TRA instead.
I don't think that would be a good alternative, since fadoink appears to want to teleport within the same room much like the two doors in the hideout.

I'm not entirely sure what fadoink's problem is here. I would like to agree with Bombchu's first hypothesis of an improperly configured <MOV, but I can't be sure.
 
Top