Here's how I have changed this -
* new command added named "set sprite resize", this allows you to set the mode of resize, by default this mode is 0 meaning sprites will not be resized when images are changed, change this to 1 and your sprite is resized automatically when an image is changed
This way you only have to add one extra line to your program and it will save you having to add an extra parameter in possibly many lines of your source code.
The original source code will work as it did in upgrade 5.8 and the sprites size will not alter when the image is changed -
cls RGB(255,0,0)
get image 1,0,0,32,32
cls RGB(0,0,255)
get image 2,0,0,256,256
sync on
spr = 1
sprite 1,mousex(),mousey(),spr
do
sprite 1,mousex(),mousey(),spr
if mouseclick() = 1 then spr = 1
if mouseclick() = 2 then spr = 2
set sprite image 1,spr
sync
loop
If you want this to change in 5.9 use this -
cls RGB(255,0,0)
get image 1,0,0,32,32
cls RGB(0,0,255)
get image 2,0,0,256,256
sync on
spr = 1
sprite 1,mousex(),mousey(),spr
set sprite resize 1
do
sprite 1,mousex(),mousey(),spr
if mouseclick() = 1 then spr = 1
if mouseclick() = 2 then spr = 2
set sprite image 1,spr
sync
loop
Will this work for everyone?