|
Post by drfloyd on Feb 11, 2021 3:44:22 GMT -6
hello, I need your help for my first game I open a window : WindowOpen(1,"COSMOS",0,0,320,200,5) CanvasOpen(1,320,200,0,0,320,200,0) I can of course load lot of images to declare sprites/tiles like this : pacman=1 LoadImage(pacman, "pacman.png") etc..... But i will have lot of PNG images ! I prefer to load a full (hidden) image (320x200) which contain all the sprites/tiles (16x16) and put these tiles into variables by cutting Can you give me the procdure ? Thank you
|
|
|
Post by drfloyd on Feb 11, 2021 3:50:41 GMT -6
I succes by using 2 canvas
canvas 0 for the hidden tiles canvas 1 for the game
and command drawimage_blit
very easy ! But how to put the canvas 0 tiles into variables ? and display these tiles with drawimage
|
|
|
Post by drfloyd on Feb 11, 2021 6:13:39 GMT -6
i am sorry, i finally found the command :
CanvasClip ( ImgSlot, src_x, src_y, src_w, src_h, flag )
|
|