Source code for the Playroom demo

Is the source code for the playroom demo available publicly? I can’t seem to find it anywhere.

I took a peek at the code in the browser which of course is not very easy to read given bundling and minification but saw enough to know there are some interesting things in there that could be good to learn from and reusable concepts.

2 Likes

I do not think we open sourced this one from what I remember.

cc @Cedric

cc @PirateJC

No,it’s not been open sourced. @rbrundritt is the first asking for it in 18 months :slight_smile:

1 Like

Is there any part of the demo that you think is worth documenting?

Being fairly new to game development I was interested in the structure of the project. A lot of the samples I’m finding have a pretty basic structure that I don’t feel would scale that well. Also curious to see how certain headaches were resolved. For example, I am playing stacking blocks in a simple knock over game as a way to familiarize myself more with babylon, but I have come across some odd behaviors. Such as the block stack “exploding” or falling over on initialization with the Havok physics engine. I positioned the blocks such that they should be in the right position and shouldn’t move and tried a bunch of things before figuring out that startAsleep was a good way to mitigate this (although still doesn’t work 100% of the time).

I also like the combination of effects in the playroom demo, like the dominos and the exploding poppers, and I feel like this demo that combines multiple things together is a nice step beyond samples that show individual concepts.

I have been going through Introduction To Creating Games | Babylon.js Documentation (babylonjs.com)(Babylon.js docs)), but there isn’t much physics in there.

1 Like

Did you check Babylon org repos for other projects? like GitHub - BabylonJS/SpacePirates: The Space Pirates game is a demo made to celebrate the Babylon.js 5.0 Release.

Most of the individual pieces that compose The Playroom are available in more detailed manner on the documentation like https://playground.babylonjs.com/#E5URLZ#20 for example.

1 Like

I hadn’t seen those resources, but like them, thanks for sharing. (gone through a few hundred links I’ve found on these forums though, lol)

Note I was mainly just asking if the code for playroom demo was publicly available. Not trying to create work for anyone.

2 Likes