From c3a1afd634fa0b76ba4e3e88521da2818fbaa48e Mon Sep 17 00:00:00 2001 From: NTBlok Date: Thu, 16 Jun 2016 20:01:47 -0700 Subject: [PATCH 1/2] Added image key for filename in json meta for TexturePacker-like format. --- glue/formats/jsonformat.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/glue/formats/jsonformat.py b/glue/formats/jsonformat.py index ea32a08..e0c4f10 100644 --- a/glue/formats/jsonformat.py +++ b/glue/formats/jsonformat.py @@ -57,7 +57,8 @@ def get_context(self, *args, **kwargs): 'sprite_path': context['sprite_path'], 'sprite_filename': context['sprite_filename'], 'width': context['width'], - 'height': context['height']}) + 'height': context['height'] + 'image': context['sprite_filename']}) if self.sprite.config['json_format'] == 'array': data['frames'] = frames.values() From 67fe44f427b17a09296c233f621936123e84e483 Mon Sep 17 00:00:00 2001 From: NTBlok Date: Thu, 16 Jun 2016 20:58:06 -0700 Subject: [PATCH 2/2] Added image key for filename in json meta for TexturePacker-like format. --- glue/formats/jsonformat.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/glue/formats/jsonformat.py b/glue/formats/jsonformat.py index e0c4f10..11be683 100644 --- a/glue/formats/jsonformat.py +++ b/glue/formats/jsonformat.py @@ -57,7 +57,7 @@ def get_context(self, *args, **kwargs): 'sprite_path': context['sprite_path'], 'sprite_filename': context['sprite_filename'], 'width': context['width'], - 'height': context['height'] + 'height': context['height'], 'image': context['sprite_filename']}) if self.sprite.config['json_format'] == 'array':