I want to make transparent graphics and, for design purpose, display them on different Z axis positions. I can't use GRP for that because it can't use more than one Z position, so what I do is:
*Make a sprite
*Add SPCOLOR 0,RGB(transparency,255,255,255)
This leaves me with two problems.
1) It takes additional Sprite Management Numbers for something that really isn't a "sprite".
2) It forces me to make my own spritesheet if I want to use customized designs. That means I need to save a GRP file just for that design.
It feels weird to do all this just for transparent graphics (on different Z axis positions).
There MUST be a better way to make some.
Transparency.
Root / Programming Questions / [.]
SamCreated:
IDK, the way you described seems good to me. Just don't make too many layers and the sprite management number shouldn't be a big deal (unless you REALLY need hundreds of sprites).
As for the custom spritesheet, if it's solid, just set it at runtime. I'm pretty sure you can still define a sprite with a command.
Sorry I don't know more, but I'm pretty sure this is just the way you have to do it.
1) It takes additional Sprite Management Numbers for something that really isn't a "sprite".Sprites are really just an instanced part of a GRP. In other graphics systems, you'll find this is more memory efficient. In SmileBasic you really don't have another option.
2) It forces me to make my own spritesheet if I want to use customized designs. That means I need to save a GRP file just for that design.How else were you planning on getting these designs to the screen? You could always use GLINE, GBOX, etc. to recreate your GRP every time the program starts. You can define Sprite Defs with SPDEF form 2, 3, and 6.
SPDEF Definition number, U,V [,W,H [,Origin X,Origin Y]] [,Attribute]