# Marble Run Simulator 2024

**URL:** <https://forum.babylonjs.com/t/marble-run-simulator-2024/47259>\
**Category:** Demos and projects\
**Tags:** game, mobile, simulation, physic\
**Created:** [January 16, 2024, 1:02pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259 "2024-01-16T13:02:35Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [January 16, 2024, 1:02pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/1 "2024-01-16T13:02:35Z")

</div>

> **Update July 2024 : Marble Run Simulator is now live on Poki [https://poki.com/en/g/marble-run-simulator](https://poki.com/en/g/marble-run-simulator)**

[![thumbnail_5](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/d/e/de10da46513f8b5768b5bf1484a0825d573a98d7.png)](https://tiaratum.com/viewer/#home)

Hi everyone ! Here’s my latest toy : **Marble Run Simulator** , which lets you build your own marble track.

 ![failproof](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/c/f/cf7b51f6cb872107314a8a13b81ef70d3437b5cb.jpeg)

It’s playable here on Itch : [https://svenfrankson.itch.io/marble-fall](https://svenfrankson.itch.io/marble-fall)  
**(update : it’s no longer playable on Itch as Poki is now the exclusive publisher for Marble Run Simulator, release should happen in June 2024)**

_(if you’re using a mobile, this version : [Marble Fall](https://svenfrankson.github.io/marble-fall/), does not lower Canvas resolution like Itch does)_

I hope I’ll be able to make a user-friendly version of the track element editor (so custom loops can be created)

Thanks for you interest and have a nice day !

---

<div class="post-metadata">

**Author:** ![Treedbox](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/treedbox/32/20615_2.png) [@Treedbox](https://forum.babylonjs.com/u/Treedbox)\
**Post date:** [January 16, 2024, 1:29pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/2 "2024-01-16T13:29:17Z")

</div>

Pretty good. 2 cent for you:

1. Make option to select a ball to be followed be camera
2. Allow zoom would be nice on the first link (touch too)

Second link has zoom.

Good job 🙂👍

---

<div class="post-metadata">

**Author:** ![carolhmj](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carolhmj/32/25918_2.png) [@carolhmj](https://forum.babylonjs.com/u/carolhmj)\
**Post date:** [January 16, 2024, 2:00pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/3 "2024-01-16T14:00:18Z")

</div>

This is SO FUN! It makes me want to watch a ton of those marble races videos 🤣 Also reminds me of building coasters in rollercoaster tycoon 🙂 I love it 🥰 Here’s my design 🙂

 ![image](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/7/e/7e3eed9bc34b492b3241e22f3bf5920c44640aef.jpeg)

Are you using Havok for the ball physics?

I like the interface for building the tracks, I have a small suggestion: allow deleting track pieces with esc/del as it’s easier than having to click on the “X” button every time

also ccing @PirateJC as I feel he’ll LOVE this too hehe

---

<div class="post-metadata">

**Author:** ![PirateJC](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/piratejc/32/1003_2.png) [@PirateJC](https://forum.babylonjs.com/u/PirateJC)\
**Post date:** [January 16, 2024, 6:55pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/4 "2024-01-16T18:55:04Z")

</div>

@SvenFrankson  
This is absolutely incredible!!! I LOVE it!

Would you consider adding it to this thread for consideration to be included in the upcoming Babylon Release Video?

[Babylon 7.0 Release Video - Community Submissions! - Announcements - Babylon.js (babylonjs.com)](https://forum.babylonjs.com/t/babylon-7-0-release-video-community-submissions/46905)

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [January 17, 2024, 9:15am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/5 "2024-01-17T09:15:25Z")

</div>

@Treedbox Yes some alternative viewpoint would be a good idea thanks, I’ll work on it on future iterations. Camera should work on both version, that’s a bug !

@carolhmj Thanks, nice circuit 🙂  
I did not use Havok for physic, mostly because I use a Path-Sphere intersection, and there’s no PhysicsShapeType for that.

@PirateJC Thanks, it would be a pleasure ! I’ll add it to this thread next month, hopefuly I will have improve it by then 🙂

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [January 22, 2024, 8:00am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/6 "2024-01-22T08:00:30Z")

</div>

Hi ! Today is Monday update, with…

- A new circuit part, the Split, which alternatively sends the marble left or right.

![image](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/f/2/f2ad5596fa41c661cd82dacd139867039931f4db.jpeg)

- A redesigned UI layout that works better on mobile.

- An optimized Ball physic.

Thanks for you interest and have a nice day !

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [January 29, 2024, 3:51pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/7 "2024-01-29T15:51:52Z")

</div>

Hi ! Today is Monday update, with…

- A new circuit part, LayerTurn, allowing to build a circuit accross multiple layers on the depth-axis

- A reworked Circuit Editor making it easier to work with procedural elements.  

- A toolbar for camera, sound and timescale manipulation.

- A reworked and more responsive main menu.  
 ![background](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/f/c/fc5915ab58028cd3fcb70dac760efc683e6a00ec.png)

- More demo tracks

It’s always playable here on Itch : [Marble Run Simulator by SvenFrankson](https://svenfrankson.itch.io/marble-fall)

Thanks for you interest and have a nice day !

---

<div class="post-metadata">

**Author:** ![carolhmj](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carolhmj/32/25918_2.png) [@carolhmj](https://forum.babylonjs.com/u/carolhmj)\
**Post date:** [January 29, 2024, 4:13pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/8 "2024-01-29T16:13:35Z")

</div>

Yessss the splitter part is so much fun!

---

<div class="post-metadata">

**Author:** ![Symbitic](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/symbitic/32/3083_2.png) [@Symbitic](https://forum.babylonjs.com/u/Symbitic)\
**Post date:** [January 30, 2024, 6:08am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/9 "2024-01-30T06:08:58Z")

</div>

Open source? Pretty please?

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [January 30, 2024, 6:18pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/10 "2024-01-30T18:18:33Z")

</div>

Yes it is, source code is available on my Github [GitHub - SvenFrankson/marble-fall](https://github.com/SvenFrankson/marble-fall)

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [February 6, 2024, 9:44am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/11 "2024-02-06T09:44:19Z")

</div>

Hi ! Today is [Weekly update v0.1.2](https://svenfrankson.itch.io/marble-fall/devlog/677668/marble-run-simulator-v012)

- **Add FlatJoin circuit part**

- Add Tracks Start/End meshes where relevant

- Add bumpers to slow down balls on Split and Join parts.

- Camera automatic modes (Ball and Landscape) disconnects on player input.

- **Camera mode now has a separate always visible window.**

- Fix bug with ToolBar resizing.

 ![editor-hd](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/c/a/cab9853d2fd22104aadd6f9dfdb384f34cfe9086.jpeg)

Thanks and have a nice day !

---

<div class="post-metadata">

**Author:** ![Symbitic](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/symbitic/32/3083_2.png) [@Symbitic](https://forum.babylonjs.com/u/Symbitic)\
**Post date:** [February 10, 2024, 12:12am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/12 "2024-02-10T00:12:22Z")

</div>

Says that repo is missing.

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [February 10, 2024, 10:46pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/13 "2024-02-10T22:46:46Z")

</div>

Yes I switched it to private for a few days, I wanted to clarify a bit the Licence under which it is released (now CC BY-NC).

It’s back online now 🙂

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [February 11, 2024, 4:37pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/15 "2024-02-11T16:37:32Z")

</div>

Yeah the “init repo” only makes sense on my station.

Currently, I work on three repos at the same time,

Nabu [GitHub - SvenFrankson/nabu: Math functions for BabylonJS-based projects](https://github.com/SvenFrankson/nabu) which are a few very simple tools I tend to use in many projects

Mummu [GitHub - SvenFrankson/mummu: Generic functions for BabylonJS-based projects](https://github.com/SvenFrankson/mummu) which contains everything related to Intersections and collisions

And Marble Run Simulator

What I do now, because I do many edits in Mummu while working on Marble Run Simulator, is that I have Symlinks pointing to Nabu and Mummu repo. This way I can seamlessly work on Mummu or Marble Run Simulator, then commit to both project separately.

I know that I could achieve that (maybe with less hassle concerning Symlink creation ^^) with a more standard build process, but

- I have low skills in theese domains
- Everytime I’ve tried to setup this kind of behavior, I eventually found it less efficient (might be because of the previous point ^^)

I’d take any hint about the standard way to do this with great pleasure ! But no need for a PR, it’s very likely it would collide with my homemade flow.

That being said, if you want to run it locally, you can !

1. Clone project
2. Add a “lib” folder
3. With the following architecture

```auto
lib/
--mummu/
----mummu.d.ts
----mummu.js
--nabu/
----nabu.d.ts
----nabu.js
--babylon.js
--babylon.d.ts
--babylonjs.loaders.js

```

Mummu and Nabu files can be found at the GitHub links above.

Then` tsc tsconfig.json` should work.

(there’s a make\_build.ps1 that I’ve written yestersday, it serves at copying only the runtime-relevant files when I want to update the online version)

(ok now that I’ve written the build process, I realize its sub-optimal when aiming at sharing it ^^)

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [February 14, 2024, 8:36am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/18 "2024-02-14T08:36:19Z")

</div>

Hello ! This week’s weekly update is [live](https://svenfrankson.itch.io/marble-run-simulator/devlog/681878/marble-run-simulator-v013)

 ![image](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/0/c/0c73f955eccaa461d7275782f060aa69858f7c6d.jpeg)

The main change is the addition of a way to evaluate the adequate circuit bank at two elements junction, which increases the amount of valid elements combinations.

The Loop piece is now procedural with a “loop count” parameter and can be extended along the Z-Axis.

Again, thanks a lot and have a nice day !

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [February 21, 2024, 8:22am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/19 "2024-02-21T08:22:49Z")

</div>

Hi ! Weekly update is [live](https://svenfrankson.itch.io/marble-run-simulator/devlog/685803/marble-run-simulator-v014)

[![](https://img.youtube.com/vi/B9y1bUd7tEw/maxresdefault.jpg "Marble Run Simulator - Create Circuit Timelapse") ](https://www.youtube.com/watch?v=B9y1bUd7tEw)

_Changelog_

- Add procedural Spiral MachinePart

![image](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/3/0/30ec61b3893da68bb2fa6b8e6e706992ef8a4a57.png)

- Replace vertical Wall with an horizontal stand

- Add 3D background

- Dragging piece is now done in the plane orthogonal to camera direction

- CreateMode shows a helper grid orthogonal to camera direction

- Reduce computational cost of Track bank

- Picking Ball in create mode now has priority over picking MachinePart

- CreateMode Grid opacity is added as an option parameter

- Reduce position randomness when adding a new MachinePart

Thanks for you interest and have a nice day !

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [February 28, 2024, 9:24am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/20 "2024-02-28T09:24:52Z")

</div>

Hi ! Weekly update is [live](https://svenfrankson.itch.io/marble-run-simulator/devlog/689431/marble-run-simulator-v015)

 ![image](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/e/7/e7fc655348da6381ddc20fdf22aade8ef18ad253.jpeg)

Beside a new **Wall procedural element** , it features

- A large physic update, Ball/Rail intersection are cheaper than ever.
- Automatic detection of performances while in Main Menu and Demo modes so graphic setting option updates accordingly
- A new, less bright background room

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [February 28, 2024, 8:58pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/21 "2024-02-28T20:58:37Z")

</div>

This could be so cool in XR in your room 🙂

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [March 6, 2024, 1:06pm UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/22 "2024-03-06T13:06:54Z")

</div>

Hello there, today is [weekly update to version 0.2.1](https://svenfrankson.itch.io/marble-run-simulator/devlog/693303/marble-run-simulator-v021)

It adds a new Challenge mode, that also acts as some kind of tutorial for Create mode.

[![](https://img.youtube.com/vi/j_In8gFLrG0/maxresdefault.jpg "Marble Run Simulator - Challenge Mode") ](https://www.youtube.com/watch?v=j_In8gFLrG0)

---

<div class="post-metadata">

**Author:** ![SvenFrankson](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/svenfrankson/32/29446_2.png) [@SvenFrankson](https://forum.babylonjs.com/u/SvenFrankson)\
**Post date:** [May 20, 2024, 9:26am UTC](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259/23 "2024-05-20T09:26:53Z")

</div>

Hi ! It’s been a while 🙂

Here’s the latest iteration of Marble Run Simulator. There’s a lot of new Track Elements and improved graphics, I feel like textured balls rolling make the whole thing more “alive” !

 ![image](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/0/8/080ae0216224f4f8d34f3c25896b3d84a6bb19e3.jpeg)

(live demo here [Marble Run Simulator Viewer](https://tiaratum.com/viewer/#machine?id=1532994488) )

The machine editor is offline at the moment, but it will be back soon on Poki once I’ve fixed all its bugs.

But the [physic engine](https://github.com/SvenFrankson/marble-run-simulator-core) and [viewer](https://github.com/SvenFrankson/marble-run-simulator-viewer) codes are still available on my Github.  
(I hope I’ll have the motivation to make some guide about it once the game it debugged and out)

Thanks for your interest and have a nice day !

PS : Here’s another demo [Marble Run Simulator Viewer](https://tiaratum.com/viewer/#machine?id=428363317)

[Next page](https://forum.babylonjs.com/t/marble-run-simulator-2024/47259.md?page=2)
