mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-01-18 09:09:47 +00:00
Fix crash when saving a loaded pxo file that has tilesets
This commit is contained in:
parent
b7c34f4233
commit
e5c7d46997
|
@ -16,7 +16,7 @@ var tileset: TileSetCustom
|
||||||
func _init(_project: Project, _tileset: TileSetCustom, _name := "") -> void:
|
func _init(_project: Project, _tileset: TileSetCustom, _name := "") -> void:
|
||||||
super._init(_project, _name)
|
super._init(_project, _name)
|
||||||
tileset = _tileset
|
tileset = _tileset
|
||||||
if not project.tilesets.has(tileset):
|
if not project.tilesets.has(tileset) and is_instance_valid(tileset):
|
||||||
project.add_tileset(tileset)
|
project.add_tileset(tileset)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue