I haven't found a guide on the specifics for creating custom NPC sprites, but I get the gist.
Every NPC has 14 frames for the animations, and also the size of the sprites seems flexible.
But what I have noticed that's problematic:
- There seems to be a "second frame" for the idle animation, that might only work on specific resource IDs, such as the Witch. Or maybe the requirement is that the other 12 frames remain black/empty for the second idle frame to be used. I haven't been able to get the second idle frame to work
with a new NPC sprite, but I haven't look in detail as to why. Maybe the client hard-coded which NPC/resource IDs have idle animations?
- Even though the sprites seem to allow any size, the offset in relation to the tile position seems to vary with each NPC (resource ID). When creating a new NPC sprite, I had to offset the Y position by -8 pixels to get it to look centered with the tile it was standing on. Looking at other NPC
sprites, it seems like the offset might not always be con sistent. I also think this might be hard-coded into the client.
- My main problem and the only real problem I noticed, is that I can't change the position of the NPC title/name. Changing the sprite size doesn't actually change the title position. I tried creating a large sprite and noticed the the name of the NPC was below the NPCs head. It seems like this
is also handled internally by the client, because I believe changing the sprites of large NPCs to a small sprite, doesn't actually change the position of the NPC title. I could be wrong.
- I haven't tried the last two animation frames (spell animation?). Does that work with a custom/new npc, and is it possible to get an npc to use a spell or the spell animation?
I could be wrong about some of this, because there's far too much testing and edge testing to be done to get a better idea of what is going on. Is there any guide or specifics on how to do certain tasks like the idle animations and changing the NPC name position?
---
Just your friendly neighborhood Programmer-Man!