![]() |
Attention | Topic was automatically imported from the old Question2Answer platform. |
![]() |
Asked By | Matty101 |
To describe, i want a sprite to be made of multiple images that will change, so each smaller image needs to be placed into the sprites image in set locations.
I’ve got this line
Overlay_drag_node.draw_texture(BaseMenu_node.spell_select_img,texture_position)
which doesn’t throw any errors, but nothings being changed on the sprite, where as:
Overlay_drag_node.texture = BaseMenu_node.spell_select_img
will change the whole sprite just fine so the references are good, i’m guessing drawtexture() function can’t be used in this way.
i want a sprite to be made of multiple images that will change
May I ask why? Why don’t you simply use multiple smaller sprites and put them right next to each other to form a bigger image?
njamster | 2020-04-12 11:26
I want the image to be scrollable in a smaller window, how i handle that has been by moving the region rect around in the sprite.
Sort of like a world map in a game, the screenspace may not be enough to encompass the whole map so you have a window that lets you drag the map around with the mouse. Adding map locations to the image as they’re found.
That becomes a lot more detailed with more sprites when i should be able to simply insert a texture into a location within another image. Java has a similar method that lets your put an image into another image at x,y position which is why i thought .draw_texture() would do the same.
Matty101 | 2020-04-12 15:42