Fix table to godot converter
This commit is contained in:
parent
dc00986f29
commit
291e14a32a
1 changed files with 1 additions and 2 deletions
|
|
@ -483,8 +483,7 @@ proc godotVariantType*(T: typedesc[Table|TableRef]): VariantType {.inline.} =
|
||||||
VariantType.Dictionary
|
VariantType.Dictionary
|
||||||
|
|
||||||
proc toGodot*[T: Table or TableRef](t: T): Variant =
|
proc toGodot*[T: Table or TableRef](t: T): Variant =
|
||||||
var dict: Dictionary
|
let dict = initDictionary()
|
||||||
initDictionary(dict)
|
|
||||||
mixin toGodot
|
mixin toGodot
|
||||||
for k, v in t.pairs():
|
for k, v in t.pairs():
|
||||||
dict[toGodot(k)] = toGodot(v)
|
dict[toGodot(k)] = toGodot(v)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue