GLBasic forum

Main forum => GLBasic - en => Topic started by: Richard Rae on 2005-Jun-01

Title: unloading sprite
Post by: Richard Rae on 2005-Jun-01
Hi Gernot.I was wondering if there was anyway to unload a sprite once you have finished using it.Also is there any way to change the image used for a particular sprite during runtime.Such as say changing a blue ball into a red ball but use the same sprite number?
Title: unloading sprite
Post by: Kitty Hello on 2005-Jun-02
Yes. That's in the manual under "advanced techniques" or something like that.
Code (glbasic) Select
LOADSPRITE "red.bmp", 0
SPRITE 0,0,0
LOADSPRITE "blue.bmp", 0
SPRITE 0, 32,0
LOADSPRITE "", 0 // free memory
SHOWSCREEN; MOUSEWAIT
Greez,
Gernot