Hundreds of features to explore
Games made in Construct
Your questions answered
Popular & trusted by schools and Universities world-wide
Construct 3 runs in the browser & works offline
Students do not need accounts with us
Free education resources to use in the classroom
World class complete documentation
Official and community submitted guides
Learn and share with other game developers
Upload and play games from the Construct community
Game development stories & opinions
When I access this.layout object in instance's onCreate function, it return undefined instead of the current layout. Am I missing anything?
Develop games in your browser. Powerful, performant & highly capable.
Why would you expect it to work? That is not a property set on instances. Only the layer is set, and you can get the layout from the layer.
But I've tried using this.runtime.running_layout, it returns null instead. Is there an event to get notified when the layer is created?
It depends when you check for the value and where from. Just look in Chrome's debugger to see what properties are there.