20 users online:  Anorakun, E-man38, GiraffeKiller, GrenCarret, JupiHornet, Lane, LightAligns, margot, MarsAmpere, nobletofu,  NopeContest, PhantasyReal, RicardoDeMelo, Royal Nico TS, Samie Zuccati, sergio_HelloKittyFan, TheCrazyBuzzyBeetle,  TickTockClock, VecchiaZim, WhiteYoshiEgg - Guests: 130 - Bots: 223
Users: 55,677 (2,384 active)
Latest user: rottencola

Sprite Programming [Legacy]

Originally posted by imamelia
What about my ASM tutorial? It will include several sections about making sprites.


I was unaware that you had one. That's...quite the detailed tutorial you have there. I feel like you'd surpass any possible tutorial that I could come with by parsecs.

Good luck you, sir.
Would you mind if I rewrote this for xkas? Obviously I'd put my own spin on it, but I have time to dedicate to something like this so you wouldn't have to worry about it.

Sure, go for it if you want. Truth be told I do have plenty of free time but this tutorial is something I don't really care about anymore. :\
And... how I do a 16x24 sprite?
Why Super Sonic and Super Sayan are identical?? ;)
Ultra Mario World progress: 0,1% (demo 1 progress 5%)
If I speak english bad, read my location.
The easiest way is doing it similarly to an 16x32 tile, but set the offsets so the tiles overlap each other (set the offset to 08 instead of 10).
Remember to set the tilemap to overlap itself so you won't waste space on duplicate (or blank) tiles.
<blm> zsnes users are the flatearthers of emulation
Yep, if the sprite is 16x32, the sprite layout would be:

X <- This tile is shifted up from Y by 16 tiles (16 + 16 = 32).

You want to shift that tile up ONLY by 8 tiles (16 + 8 = 24) so all that's required is changing the Y displacement to 08 instead of 16 in the 16x32 GFX routine. Here's the code if you're interested.
Also, I want to make small announcement. I will be "converting" this tutorial to an xkas/asar format once the new text editor for posting is implemented. I already converted a good amount of my first post but editing has become a pain with the current editor that I gave up. :P

And while I'm at it I will probably fix many errors, add more routines and clarify a few more points. I'll edit this post when I'm done.
Originally posted by Iceguy

LDA $13
AND #$01
STA $0302,y

LDX $02
ORA $64
STA $0303,y

How unequivocally detestable.
Post edited to spare others this horror.
<blm> zsnes users are the flatearthers of emulation
This tutorial is the Wikipedia?

Good tutorial, very detailed.
My channel on Youtube

Hell of Pain - My hack

I almost made the generator.=0
Horray, i finally made the generator. i forgot to make bcc return in to bcc return2 and turn it back to normal. =D
First of all, I apologise for the late reply. I haven't been checking this thread often.

Lots of sprites are being spawned probably because the routine that spawns the sprites is running again and again. You should make it run only once using a RAM Address. Set a flag to some non-zero value in the spawning code and prevent the routine from running if said flag is non-zero.
I'm not so good at making sprites, but at least I can make bone-throwing Hammer Bros, giant enemies and (rarely) bosses by simply changing some code. One of my sprites is in the Waiting Sprites Section.
By the way, good tutorial, but I need a video demonstration so I can improve! Thank you very much!
What would Brian Boitano do?

Image and video hosting by TinyPic
Sorry to bump this thread, but your forgot the sprite's object clipping routine, like $019138. Ram address $1588 needs that subroutine in order to work.
Give thanks to RPG hacker for working on Asar.
Moved it to the old tutorials because I made a new, up to date one.