CodeAndWeb / texturepacker-godot-plugin

AtlasTexture and TileSet importer for Godot engine. Loads sprites sheets created with TexturePacker
MIT License
65 stars 17 forks source link

A recent ENUM bug fix in 3.1 won't allow for this syntax anymore. #5

Closed ghost closed 5 years ago

ghost commented 5 years ago

In upcoming version of 3.1 the add-on will break because of this fix to enum constants: https://github.com/godotengine/godot/pull/23648

The syntax will have to use the full notation.

harrisyu commented 5 years ago

Yes I can comfirm,and the code need to change to: func get_preset_name(preset): match preset: Preset.PRESET_DEFAULT: return "Default"

CodeAndWeb commented 5 years ago

Thanks a lot for your time and for updating the importer!

CodeAndWeb commented 5 years ago

What about ERR_FILE_NOT_FOUND and ERR_FILE_UNRECOGNIZED? Must these be Error. ERR_FILE_UNRECOGNIZED and Error. ERR_FILE_NOT_FOUND ? (in image_loader.gd)

ghost commented 5 years ago

@CodeAndWeb Not a problem.

ERR_FILE_NOT_FOUND and ERR_FILE_UNRECOGNIZED should still work.

Thankfully the change only appears to affect the script declared enumerations. The built-in / global ones still work as they did before.