I was forced to use Defold for a collaboration. I clearly prefer Solar2d for every feature. Except 1 – layers.
Not a big deal, but I decided to create layers:
V.sceneGroup = self.view
V.bg = display.newGroup()
V.base = display.newGroup()
V.action = display.newGroup()
V.veneer = display.newGroup()
V.top = display.newGroup()
V.sceneGroup:insert(V.bg)
V.sceneGroup:insert(V.base)
V.sceneGroup:insert(V.action)
V.sceneGroup:insert(V.veneer)
V.sceneGroup:insert(V.top)
Not perfect, because layers and groups are different – For my current project I need parts of an object to be in different layers for interleaving. Move together, but retain their layer. But easier to do coordinated move than all those toFront and toBack.
Then I wondered: is there a performance or stack corruption or other problem that I should worry about from all that nesting?