You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Tiled version 1.9.2
Plugin version 2.3 (same with 2.4)
Godot version 3.4.5
**Issue description :
After Tiled 1.9x, Godot creates "StaticBody2D" objects instead of "Area2d" objects like previously.
In Tiled 1.9.2, uppon re-opening previously created maps, object layers that had objects with "type" = "area" are converted to "class"="Area". The "Type" property is lost.
Tiled importer plugin now creates StaticBody2D.new() instead of Area2D.new() because it relies on the "type" property instead of the new "class" property. (var body = Area2D.new() if object.type == "area" else StaticBody2D.new())
Steps to reproduce
In Tiled 1.9x, create object layer with rectangle shape with class property = "area". Import in godot : Godot will crete a "StaticBody2D" instead of "Area2d".
**Temporary fix
I modified "tiled_map_reader.gd", and changed this line :
var body = Area2D.new() if object.type == "area" else StaticBody2D.new()
for this :
var body = Area2D.new() if object.type == "area" or object.class == "area" else StaticBody2D.new()
Thanks !
The text was updated successfully, but these errors were encountered:
Tiled version 1.9.2
Plugin version 2.3 (same with 2.4)
Godot version 3.4.5
**Issue description :
After Tiled 1.9x, Godot creates "StaticBody2D" objects instead of "Area2d" objects like previously.
In Tiled 1.9.2, uppon re-opening previously created maps, object layers that had objects with "type" = "area" are converted to "class"="Area". The "Type" property is lost.
Tiled importer plugin now creates StaticBody2D.new() instead of Area2D.new() because it relies on the "type" property instead of the new "class" property. (var body = Area2D.new() if object.type == "area" else StaticBody2D.new())
Steps to reproduce
In Tiled 1.9x, create object layer with rectangle shape with class property = "area". Import in godot : Godot will crete a "StaticBody2D" instead of "Area2d".
**Temporary fix
I modified "tiled_map_reader.gd", and changed this line :
var body = Area2D.new() if object.type == "area" else StaticBody2D.new()
for this :
var body = Area2D.new() if object.type == "area" or object.class == "area" else StaticBody2D.new()
Thanks !
The text was updated successfully, but these errors were encountered: