Assembly Hacks

Jun 25, 2006 at 2:05 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
Infinit Hover
To prevent the Booster from running out of juice, simply change the following line to the one underneath...
85 D2 74 16 83 3D E8 E6 49 00 00 74 0D A1 E8 E6
85 D2 74 16 83 3D E8 E6 49 00 01 74 0D A1 E8 E6
This tells the code to stop removing "juice" from the Booster once it hits 1 instead of 0. This is the simplest way of doing this.

Changing Text Color
Offsets 0141EE and 014358 push an RGB triplet onto the stack and later drop into a text-rendering function. The value you will find at these offsets is 0x11002200. Each byte is a different component (Red Green Blue Unused.) Change to whatever you want (ie, 0xFF000000 -> completely red.)

There are quite a few instances of regular text and I don't feel like going through them all right now. Look for 0xFFFFEF00 in your executable and try replacing them with colors of your own - test them one by one. I don't think that string exists outside of text colors so you should be fine. I'll update this when I feel like looking through offsets for the right ones. :)

Manipulating Oxygen
Offsets 0x0169A3 and 0x0169CA control the oxygen you get when you go underwater. Oxygen depletes at the rate of 1 per 1/10th of a second, but you only see every 10 unit (so 1000 means 100, 350 means 35...) They're set to 0xE8030000 (0x000003E8; which is 1000.) Try changing them to, say, 0xF4010000 (500; 50 units) or 0xC4090000 (2500; 250 units.)

Infinit Ammo
While this could be done as an assembly hack, you just need to give a weapon 0 ammo when you obtain it. So why bother. ;)

Startup Info
Startup info is set in a routine at 0x014B50. You can find the startup information for health at 0x014BCF (current health) and 0x014BD8 (max health.) The other MOV instructions, I'm not clear on yet. 0x1000 and 0x0A000 get set a lot.

Fun with Water
The sounds played when you jump in and out of water are PUSHed onto the stack. You can find the instructions at 0x00016216 and 0x000162bd respectively. Just change the value the PUSH instruction uses from 0x22 to whatever sound you want.

Basic Weapon System Info
0x0009366C contains the weapon experience tables. Each is 3 x 4 bytes in length. For instance, 0x00093678 to 0x00093684 is for the shooting star. The majority of the info on a weapon (number of shots, frames, sound, behavior...) is hard-coded into the code itself, but some basic info exists elswhere in the executable. I'll leave that one for the aspiring hacker to find. Here's a hint: it's 0x2C in length and starts by the damage.

Weapon Energy's duration can easily be altered by changing a single value. This should be around 0x0026AA0.
08 81 79 6C 90 01 00 00 7E 38 8B 55 08 8B 42 6C

Also, the following two values control how much a weapon energy crystal has to be worth in order to switch sizes (ie, medium and large.) This is somewhere in the vicinity of 0x0026A10.
48 44 89 4D 8C 83 7D 8C 05 74 08 83 7D 8C 14 74

The sound it makes when bouncing can be found here, near 0x00267D0.
E1 0D 74 38 6A 01 6A 2D E8 63 9E FF FF 83 C4 08
 
Jun 25, 2006 at 2:06 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
I thought I'd seperate the Original Sin hack thread from the actual findings I've been making. The above is a document I'm going to maintain whenever I find stuff that might interest people. I'll edit the first post whenever I add new stuff and make a new post in this thread every once in a while to mention updates.

Fun times for everyone. ;)

More complex hacks probably won't make their way here. I'm trying to keep this general-purpose and accessible to all.

NOTE THAT THESE ALL COME FROM v1.0.0.6! PLEASE UPDATE YOUR VERSIONS.
 
Jun 25, 2006 at 2:11 AM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 33
Pronouns: No homie
Well, nice hacks, but all u use in ur EXE can be spyed by hackers u might know :/
HEX WIZARD can compare two EXE files, and hackers can easily look wich hex u edited... So take care!

And i'm asking you first because you found these hacks, all hacks you post here, can i make them into a special editor for cave Story?

EDIT:
Well the First the Booster hack!
U can have other booster jetpack animations!
try to set the value to 03 and 04!
 
Jun 25, 2006 at 2:18 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
ShInInG PhAnToM said:
Well, nice hacks, but all u use in ur EXE can be spyed by hackers u might know :/
HEX WIZARD can compare two EXE files, and hackers can easily look wich hex u edited... So take care!
Uh, yeah... and...? That's the whole point of hacking, you realize? It's exactly what we're doing with the original game. If someone has the skills to figure out what's what and can use it to their advantage, they're doing what a hacker should be doing. That behavior should be encouraged.

The stuff I'm posting is all public domaine. After all, I'm not the author of Cave Story, so neither I nor anyone has any claim to this stuff. I just made the discoveries, not the game. So I couldn't care less what anyone does with any of it. ;)

Once I start posting code rewrites, that'll be a whole different story altogether.
 
Jun 25, 2006 at 2:28 AM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 33
Pronouns: No homie
So i can make a editor or not ???
Well, i searching in the EXE too for something, only thing ive found is to make the game crash if i press the left key when i jump ;) lol
Well, but this hacks are no major hacks at all :)
The thing we must find out is:
Weapon hacking (how much damage how fast wich tile)
NPC Script Hacking
 
Jun 25, 2006 at 2:31 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
ShInInG PhAnToM said:
Weapon hacking (how much damage how fast wich tile)
NPC Script Hacking
I figured out the first one, but I'm keeping this stuff to myself for the time being until my hack is complete. Wouldn't want my more impressive findings to become unimpressive, common material by the time the hack is complete. ;) Still haven't found anything on NPCs yet, though.

Like I said, this is public domain information, so if you want to make an editor out of it, it's your call.
 
Jun 25, 2006 at 2:36 AM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 33
Pronouns: No homie
Well, if ur hack is complete (ver. 1.0 or another) u releasing a complete of ur material?

EDIT:
Well but don't be mad if i find the same as you, and realeasing it in the editor (or just tell me what you found what i realease when youre done with your Side Projekt!)!
 
Jun 25, 2006 at 2:39 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
Probably not. I abhore giving people answers on a silver platter. It's always been my firm belief that if you want something, you should work for it. Little tidbits are fine, pokes and prods in the right direction too, but answers all neat and ready to use without an effort handed down on a silver platter? Not a whelk's chance in a supernova. ;)

Sorry. Help with x86 assembly and a few interesting offsets, I'll be glad to provide. But like I said before, my views on hacking involve the hack being the cumulative sum of the author's efforts, skills, and creativity; not the author's ability to use someone else's work for their own without knowing what's actually going on. The latter is just sad plagiarism and proof that the person doing the hack is an untalented failure. ;)

Maybe a failure with plenty of creativity, but not worthy of the title of hacker by a long shot. ;) At best a meddling kid on his/her way of being one - we've all got to start somewhere after all.
 
Jun 25, 2006 at 2:48 AM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 33
Pronouns: No homie
Well i want a editor so that everyone can edit it! Well, but i mean not that every dummy can make a (bad) mod!
 
Jun 25, 2006 at 2:50 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
ShInInG PhAnToM said:
Well, but i mean not that every dummy can make a (bad) mod!
I like that view. But I still think an editor should just be a backup tool to automate needlessly simple stuff, and that the real work should be done through blood, sweat, and tears.

Well, no tears. Probably no blood either, unless you have a 4-5 year old chinese water dragon who enjoys scaling your legs with his sharp claws. The sweat, there's gonna be a lot of that, be sure of it. >"<
 
Jun 25, 2006 at 2:55 AM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 33
Pronouns: No homie
Well, everything that help me tell me...
So iam going off, working on my mod i hope you will like it, it has a new cooler (Blueish Greeney) Style (With a bit grey) and then i go to bed.
 
Jun 25, 2006 at 2:59 AM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 33
Pronouns: No homie
Also iam very interested:
Wich programm u use for?
IDAPro?
 
Jun 25, 2006 at 7:15 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
Added some startup information for those of you who want to start up with more (less?) than 3 health. 'Course you could just do that in the startup event but hey...

Edit: I use my own x86 disassembler. I can simply dump a range of machine code to a text file and work at it there. It supports labels, so I can label common addresses and offsets for easy reference. I generally stay away from Google's first results when looking for something. The real gold's in indie dev tools, not in big commercial software that's more bloat than usefulness. ;)

I look forward to your mod, mate. Good luck!
 
Jun 25, 2006 at 4:41 PM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 33
Pronouns: No homie
Thanks, for you too!
I hope you find more cool!

Well you know one good disasembler?
I only found one, and the one isn't lucid!
 
Jun 25, 2006 at 9:31 PM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
Anything that can output mnemonics instead of raw hex is fine. All the additional fluff won't make you into a better machine code hacker. In fact, bloat means it's more of a hassle to dump stuff and get what you want.

Like I said, I use my own because I couldn't find anything that was command line (I HATE point and click interfaces... so slowww...) and that suited my needs. But anything you can find that can dump code to a text file is all that you'll never need. Your own skills as a machine code hacker and your understanding of the processor you're working with will be far more important than the program you're using.

Hefty programming experience, particularly in working with algorithms and patterns, is also a very important thing to have. If you can't spot a bubble sort algorithm in all that mess, you're going to be scratching your head for quite some time over what should be really simple code.
 
Jul 3, 2006 at 12:35 AM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
Added a quick bit of info on water. I realized I had accidently set my hack's new weapon's sound to the same than water used. Seeing as my hack uses custom sound effects, jumping into water sounded like your little dude was getting deep-fried.

I figured I'd share the knowledge.
 
Jul 3, 2006 at 2:30 PM
Senior Member
"Huzzah!"
Join Date: Mar 24, 2006
Location:
Posts: 194
Age: 35
Pronouns: he/him
RuneLancer said:
Sorry. Help with x86 assembly and a few interesting offsets, I'll be glad to provide. But like I said before, my views on hacking involve the hack being the cumulative sum of the author's efforts, skills, and creativity; not the author's ability to use someone else's work for their own without knowing what's actually going on. The latter is just sad plagiarism and proof that the person doing the hack is an untalented failure. :)

this sounds a lot like what the hermet gunsmith said before he saw how well quote handeled his gun
 
Jul 3, 2006 at 5:21 PM
Been here way too long...
"..."
Join Date: Jun 25, 2005
Location:
Posts: 372
caveoholic! said:
this sounds a lot like what the hermet gunsmith said before he saw how well quote handeled his gun

Except that the Hermit was making the exact opposite point, that there are creators and users, and that there is nothing at all wrong with using the work of someone else as long as you understand and respect the work of those that created your tools.

Rune, on the other hand, is saying that it should only be those that create a tool that use it, and that everyone should do things the hard way. Personally, I think that creating an easy editor for those that have no assembly knowledge would be a great idea, because there could be someone who is a wonderful game designer, and could have great plans for a Cave Story mod, but doesn't have the experience or wish to learn assembly. Even if they didn't do all the work, the end result could still be a great mod that people enjoy. Besides, people definately will give major credit to the creator of the tool, as well as the one who uses it, and those that claim all the credit will be shunned by the community. :p

Just my two cents.
 
Jul 3, 2006 at 7:21 PM
Senior Member
"Huzzah!"
Join Date: Mar 24, 2006
Location:
Posts: 194
Age: 35
Pronouns: he/him
Osmose said:
Except that the Hermit was making the exact opposite point, that there are creators and users, and that there is nothing at all wrong with using the work of someone else as long as you understand and respect the work of those that created your tools.

Rune, on the other hand, is saying that it should only be those that create a tool that use it, and that everyone should do things the hard way. Personally, I think that creating an easy editor for those that have no assembly knowledge would be a great idea, because there could be someone who is a wonderful game designer, and could have great plans for a Cave Story mod, but doesn't have the experience or wish to learn assembly. Even if they didn't do all the work, the end result could still be a great mod that people enjoy. Besides, people definately will give major credit to the creator of the tool, as well as the one who uses it, and those that claim all the credit will be shunned by the community. :p

Just my two cents.

No I said BEFORE he saw how well quote handeled his gun see look

"<CLRYou know,<NOD
I've long believed that one's
weapons should be crafted by
oneself.<NOD
That one who fights with another's
weapons and considers that force
his own is witless.<NOD
That one who blames his tools for
that which his own power cannot
achieve is a fool.<NOD<CLR"

Runelancer said:
Sorry. Help with x86 assembly and a few interesting offsets, I'll be glad to provide. But like I said before, my views on hacking involve the hack being the cumulative sum of the author's efforts, skills, and creativity; not the author's ability to use someone else's work for their own without knowing what's actually going on. The latter is just sad plagiarism and proof that the person doing the hack is an untalented failure.

see the similarities
 
Jul 3, 2006 at 8:56 PM
The Bartender
"All your forum are belong to us!"
Join Date: Jun 18, 2006
Location: Montreal, Canada
Posts: 581
Age: 40
That's more or less right. It seems you respect, though don't necessarily agree, this opinion, and I feel the same towards yours, so it's all good. :)

The problem is, there is absolutely no such thing as an editor for assembly. There's simply no getting out of it - you need to be able to stop relying on editors and get really dirty with some very heavy stuff if you want to push a hack beyond the traditional "new graphics and maps" changes. The closest there would be is a program with a few built-in hacks that can be switched on or off - not something that would allow you to make any changes of your own.

If a game were 100% scripted, both engine and content, that would solve everyone's problems now, wouldn't it? Unfortunately computers don't work that way and writing such a game would be a hassle - interpreting a script is MUCH slower than running machine code directly... still, a game like that COULD exist, given those limitations, but the script parser would still have to be written as code. And this isn't the case with Cave Story, so it's a moot point. But it'd be nice for everyone involved.

I'm a hacker, through and through. I've seen what the game engine can do, and having the same gameplay rehashed with a different storyline where Quote is actually Curly or both Quote and Curly are government agents investigating some strange cult, is about as uninteresting as it gets. Hacking is about working until the wee hours of the morning to force code to do what you want it to do just so you can smile in the morning over a mug of coffee, totally thrashed, at some new effect you've hammered into the code. :D Or at least spending a few hours poring over some assembly listings, tweaking, and learning how the game engine works. When the end result comes out just like you want it, you've succeeded, and there's no better feeling than success after gruelling effort. If it were just a matter of storyline, I'd write a fanfic (and feel like a part of me has died in the process :p )

I'm here to do just that. And if in the process someone happens to learn something more advanced than what they had experience with beforehand, awesome. But I'm not here to get anyone's approval, just to get results and to share the fruits of my labor with everyone else.

Besides, the hermit smelled weird. I just took a shower. We're too different, it'll never work out... :(
 
Back
Top