Hi there,
i am new to Defold and lua. So a big Hello an a big Thank You for giving us your Engine for free and on top supporting us. Also hello and thank you to the all the other Devs around here for your support.
I have this piece of code:
animal = "tiger"
path = "/animals/" .. animal .. ".atlas"
go.property("animalImage", resource.atlas(path))
go.set("#animalSprite", "image", self.animalImage)
this ended up in the following errors:
ERROR:GAMEOBJECT: Properties can not be of type 'nil'.
ERROR:SCRIPT: animals/animals.script:9: the property 'image' of '#animalSprite' must be a number
stack traceback:
[C]:-1: in function set
animals/animals.script:9: in function <animals/animals.script:5>
what am i doing wrong? If i put the path directly in the resource.atlas("") all is fine. Also hash(path) produces the same error.