Stacking Sprites

marco75

New member
I have question about the following line in the article named Graphics overview
http://www.chronocrash.com/apps/wiki/obor/index.php?title=Graphics_Overview#Sprites

For sake of argument, it is technically possible to stack entities together into a single larger unit just as hardware sprites are stacked together to assemble an image. However, due to the abundance of available color and user defined aspect of OpenBOR images, this technique is a superfluous complexity. To date it has never been used in an OpenBOR module.

I would like to try sprite stacking for weapon animations. So the image of the weapon is stacked to the player or enemy sprite holding it. What are the commands and variables to tell the engine how to stack two images together? The benefit would be that the same weapon sprites can be reused for many characters, and would make it easier to have more functionally identical but graphically different weapons to suit different level themes.
 
You're not the first person to think of this. I need to update the wording there anyway. Sprite stacking is quite common - it's the recommended way to add particle effects and other tidbits.

It's stacking to create a single hard image no one bothers with, and for a lot of very good reasons. I've experimented with the idea for head-swaps and weapons too. I can promise you the cons easily outweigh the pros. About the only good reason to mosaic images would be for clothing swaps or to build a true color image from three RGB tiles. Neither is technically difficult, but are tedious to the max.

wh-ninja-fuuma-idle-adok.gif


wh-ninja-fuuma-idle-adok-mask.gif


wh-ninja-fuuma-idle-adok-scarf.gif


wh-ninja-fuuma-idle-adok-all.gif


If you still want to, then it does require use of script - a combination of spawning (to bring in the second entity), binding (to align and move them together), and destruction. If that doesn't scare you off, I'll see about adding some more nuts and bolts detail. :)

DC
 
I can see your idea marco. This idea would do great for characters with generic size and generic action animation such as Final Fantasy characters

If you still want to, then it does require use of script - a combination of spawning (to bring in the second entity), binding (to align and move them together), and destruction.

I agree about the binding part. As for spawning and destructing, I'm thinking the possibility to spawn and bind the weapon together when player is spawned into the level. The weapon is set to use blank images as default setting. When player acquires a weapon, the weapon is simply set to display the former
IOW the spawn and destroy are only done when player is spawned and die, respectively

Haven't got the time to test this method though
 
Back
Top Bottom