Browse Source

fix a mistake

sanikoyes 11 years ago
parent
commit
bc4e37b132
1 changed files with 1 additions and 1 deletions
  1. 1 1
      scene/resources/texture.cpp

+ 1 - 1
scene/resources/texture.cpp

@@ -583,7 +583,7 @@ void AtlasTexture::draw_rect_region(RID p_canvas_item,const Rect2& p_rect, const
 
 
     if(scale.x >= 0 && scale.y >= 0)
     if(scale.x >= 0 && scale.y >= 0)
     {
     {
-	    Rect2 dr(src_c.size*scale,p_rect.pos+ofs*scale);
+	    Rect2 dr(p_rect.pos+ofs*scale,src_c.size*scale);
 	    VS::get_singleton()->canvas_item_add_texture_rect_region(p_canvas_item,dr,atlas->get_rid(),src_c,p_modulate);
 	    VS::get_singleton()->canvas_item_add_texture_rect_region(p_canvas_item,dr,atlas->get_rid(),src_c,p_modulate);
     }
     }
     else
     else