improve stability of mikunyan-image
This commit is contained in:
+2
-2
@@ -63,8 +63,8 @@ assets.each do |asset|
|
|||||||
unless textures[tex_id]
|
unless textures[tex_id]
|
||||||
tex_obj = asset.parse_object(tex_id)
|
tex_obj = asset.parse_object(tex_id)
|
||||||
if tex_obj
|
if tex_obj
|
||||||
textures[tex_id] = Mikunyan::ImageDecoder.decode_object(tex_obj) if tex_obj
|
textures[tex_id] = Mikunyan::ImageDecoder.decode_object(tex_obj)
|
||||||
json[tex_id] = {:name => tex_obj.m_Name.value, :width => textures[tex_id].width, :height => textures[tex_id].height, :path_id => tex_id, :sprites => []}
|
json[tex_id] = {:name => tex_obj.m_Name.value, :width => textures[tex_id].width, :height => textures[tex_id].height, :path_id => tex_id, :sprites => []} if textures[tex_id]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user