Okay...
I have a dictionary of textures in the function draw
Is there a way to convert all the textures in a dictionary into one bigtexture ?
var layersCopy = {};
var layersCopyMousePoint;
func _process(delta):
mXG = snapped( get_global_mouse_position().x, 32 );
mYG = snapped( get_global_mouse_position().y, 32 );
mGpos = Vector2 (mXG, mYG);
if ( toolCheck == 1 && mouseInEditor == true && top_2D.button_pressed == true ):
SelctRect = Rect2(mXG, mYG, 32*11, 32*11 );
if ( Input.is_mouse_button_pressed(MOUSE_BUTTON_LEFT) && SelctPress == true ):
SelctPress = false;
elif ( ! Input.is_mouse_button_pressed(MOUSE_BUTTON_LEFT) && SelctPress == false ):
SelctPress = true;
layersCopy = layers.Lnum[ layerPOS ]; ############### MOUSE ICON COPY/PASTE
layersCopyMousePoint = mGpos; ##################
print(layersCopy)
func _draw():
if ( toolCheck == 1 && mouseInEditor == true ):
draw_rect( SelctRect, Color.YELLOW, false, 2 );
draw_string (font, Vector2(mXG, mYG-30), "mGpos2: " + str(mGpos))
if ( SelctText != null ):
for i in layersCopy:
draw_texture( layersCopy[i], mGpos + i - layersCopyMousePoint );
print(layersCopy):
{ (224, 96): <ImageTexture#-9223367288483132947>, (224, 128): <ImageTexture#-9223367288432801300>, (224, 160): <ImageTexture#-9223367288382469653>, (224, 192): <ImageTexture#-9223367288332138006>, (224, 224): <ImageTexture#-9223367288281806359>, (256, 96): <ImageTexture#-9223367288231474712>, (256, 128): <ImageTexture#-9223367288181143065>, (256, 160): <ImageTexture#-9223367288130811418>, (256, 192): <ImageTexture#-9223367288080479771>, (256, 224): <ImageTexture#-9223367288030148124>, (288, 96): <ImageTexture#-9223367287979816487>, (288, 128): <ImageTexture#-9223367287929484846>, (288, 160): <ImageTexture#-9223367287879153218>, (288, 192): <ImageTexture#-9223367287828821804>, (288, 224): <ImageTexture#-9223367287778513138>, (320, 96): <ImageTexture#-9223367287728158479>, (320, 128): <ImageTexture#-9223367287677826845>, (320, 160): <ImageTexture#-9223367287627495029>, (320, 192): <ImageTexture#-9223367287577163333>, (320, 224): <ImageTexture#-9223367287526832050> }