Currently, I am working on a 2D top-down style RPG (in Pygame; newest version of Python), and I want to make the character drawing process as simple as possible. However, I have no earthly idea of how to pull it off.
I know already that drawing out sprites using a for loop will kill my game's performance, and then I'd also have more code to worry about.
What I want to do is take a 'nude' sprite, put eyes, hair, and clothes on top of it, and save that as a new image.
(MaleSprite.png + Eyes1.png + Hair1.png + Clothes1.png = Spritesheet.png)
I already have a sprite sheet for a nude sprite, and I also have a sprite sheet for a hair style. I need to shift the hair up by two pixels and then draw it on top of the character, then save that to a new image (since the sprite sheet for the character is 64px tall, the new image will be 66px tall).
I'll handle any other dependencies that come up in the code, I just need to combine these images, and I believe I should be using Pillow for this.
I want to get the player's choices for eye color, hair, and clothing, and then write that to their player file. After that, the makesprite() function should take the sprites, adjust them as needed (hair will be shifted up by two pixels, hats will probably be more), and then save that as a new sprite sheet (png) that I can use in my sprite.draw() function.
sprite.__init__()
. Sounds quite flexible actually. – Kingsley