This is my first experiance with dynamic sprites, so I need a little nudge to get me started.
All I want to do is draw an image onto the screen, preferbly in front of everything else on screen. I did a quick search and searched through the manual and just can't understand it.
I tried:
DrawingSurface *surface = Room.GetDrawingSurfaceForBackground();
surface.DrawImage(0, 0, 63);
surface.Release();
But then I couldn't delete it or clear it without the game crashing, plus it draws on the background, behind the characters.
Again, all I need it a push into getting started and for how to delete it when finished.
Example: Draw image to screen, wait for 3 seconds, clear sprite from screen and delete it.
Then it's better to use an overlay imho.
Overlay* myOverlay = Overlay.CreateGraphical(0, 0, 63, false);
Wait(120);
myOverlay.Remove();
EDIT: I thought the alpha parameter was optional.
Dualnames... thank you. :D
Apparantly the final paramater (4th) isn't optional, so I had to set it to true/false. No matter though. Thanks again.
If you ever need to draw something onto a sprite and then display it this way you can use the DynamicSprite.GetDrawingSurface function to get the surface you need. If you then use that DynamicSprite with an Overlay you can delete the sprite and the Overlay won't be affected. If you display the sprite on a GUI though, you must not delete the sprite and must keep a global pointer to it available or you'll run into problems. Just so you know..;)