Data.get(...) can be used to return data of numeric, string, or JSON object types, however the resulting command from Data.get(...) appends a scale of 1 at the end, making anything but numeric get calls invalid.
Example:
The following should return the object with the players inventory
Dart:
Data.get(Entity.Player(), path: "Inventory")
mcfunction:
data get entity @p Inventory 1
Minecraft error message:
"Can't get Inventory; only numeric tags are allowed"
Possible resolution:
Do not output scale by default since it implicitly returns the scale of 1 anyway.
data get entity @p Inventory
Data.get(...) can be used to return data of numeric, string, or JSON object types, however the resulting command from Data.get(...) appends a scale of 1 at the end, making anything but numeric get calls invalid.
Example: The following should return the object with the players inventory Dart:
Data.get(Entity.Player(), path: "Inventory")
mcfunction:data get entity @p Inventory 1
Minecraft error message: "Can't get Inventory; only numeric tags are allowed"Possible resolution: Do not output scale by default since it implicitly returns the scale of 1 anyway.
data get entity @p Inventory