News:

Don't forget to visit the main site! There's lots of helpful docs, patches, and more!

Main Menu

[SM] Hacking Ridley

Started by Crashtour99, August 03, 2010, 07:35:23 AM

Previous topic - Next topic

Crashtour99

For those who may or may not remember my Ridley gfx edit...
[spoiler]http://www.youtube.com/watch?v=_VP3dTISoL8[/spoiler]

I was thinking about taking this a bit further.  I know that Jathys said it probably wouldn't be too hard to relocate where the fireballs shoot out from, and I was wondering if someone who knows how to do that would be able to tell me.  (I'm confident I can do it on my own, I just don't know the HOW)
I was also wondering if the same thing would work to relocate the "tail".  And not only that, but if it's possible to have 2 "tails", either operating in tandem or separately from each other (and if you can make their base move to different positions in the sprite as it changes animation).  I was reading over Sadi's guide for editing enemy tile animations and came up with some ideas that would make this edit even better.

Also, I was wondering how hard it would be to change Ridley's palette structure, i.e. making it like a normal boss enemy instead of an unintelligible mess.  Repointing it to freespace shouldn't be an issue, but from there I'm not sure how to progress.

Scyzer

It's possible, but would be quite difficult. Ridley's tilemaps are among the most complicated i've seen (even worse than mode7 tilemaps >.>) and they're all over the place.
Here's Ridley's AI ASM... go nuts :P

Crashtour99

Well, I thought I was on to something with this bit from the fireball calculation...
facing left
$A6/E855 A9 E7 FF    LDA #$FFE7  ;-19 pixels X position 136855
$A6/E866 A9 D5 FF    LDA #$FFD5  ;-2B pixels Y position 136866
facing right
$A6/E8A1 A9 19 00    LDA #$0019  ;-19 pixels X position 1368A1
$A6/E8B2 A9 D5 FF    LDA #$FFD5  ;+2B pixles Y position 1368B2


but apparently all that changing those values does is make him miss horribly and not actually change the spawn point of the projectiles.   :stern:  Hmmmm...

Scyzer

I'm not sure what the code is for that. i'd literally just turned off my computer, so i'll have a look later (i'm on my phone atm). it's also like 2.30am D:

anyways if you know asm, you should look at the whole subroutine with those values, as that will give you an idea of how they come into play, then you might be able to do something with them. the other option is to run a breakpoint of enemy projectile x/y positions in the ram, and see when they come into existance.
and now sleepy for me :P

Crashtour99

Well, after looking at the routine and what playing with those values does, I'm pretty sure that they're only used for angle calculation.

As for the breakpoints, you mean like one of these from Kej's RAM map?

7E:1991 - 7E:1992    Current e/r projectile

7E:1A4B - 7E:1A6E    X position of projectile, in pixels
7E:1A6F - 7E:1A92    X subpixel position? (guessing)
7E:1A93 - 7E:1AB6    Y position of projectile, in pixels
7E:1AB7 - 7E:1ADA    Y subpixel position? (guessing)

7E:1B47 - 7E:1B6A    Instruction address / Graphic AI for e/r projectiles
7E:1B6B - 7E:1B8E    e/r projectile graphic pointer. Points to data entry: #sprites, (2-byte X, 1-byte Y, sprite bytes 3-4, 5 total bytes per sprite) (7E:1B7D - MB's intro hit counter?)
7E:1B8F - 7E:1BB2    Frames Delay for 1B47

I hadn't even thought about looking at those, I was too concentrated on sifting through Ridley's AI stuff.  LOL

DSO

What you want is to find where $12 and $14 are written to just before a JSL $868097, then to tweak the system that calculates what is written to $12 and $14, as those are used for X and Y coordinates when the JSL $868097 is done to spawn a projectile.

Crashtour99

Ah, that explains it!  I was on the right track the first time, just in the wrong place.  The first ones I tried changing were before a different JSL.  Thanks DSO, that helps a lot.   :^_^: