My final-year Computer Science dissertation at the University of Exeter (Sep 2023 – May 2024). It's a 3D motorsport race in the browser where AI controls both the driving and the race strategy. Most racing-management games let the AI drive while you make the strategy calls. Here the AI makes those calls too, and you watch the race unfold like a broadcast.
- Up to 20 AI cars race on four selectable circuits, rendered in 3D with Three.js.
- Qualifying sets the starting grid.
- A live timing tower shows each car's position, speed, tyre compound and tyre wear.
- 2D and 3D views of the same race.
Each car is a YUKA vehicle that follows a predefined racing line using steering behaviours: path following to stay on the line, and obstacle avoidance to race around the other cars. Three.js renders the cars and tracks from glTF models.
A neural network trained with Brain.js decides, for each car, when to pit and which tyre compound to fit: soft, medium, hard or wet. It bases the decision on tyre wear and track conditions.
- Training happens offline. Node.js scripts (
src/pages/node) generate race data and train the network. - The trained model runs in the browser. It's saved as
trained_network.jsonand loaded by the race page, so no server is needed.
The dissertation evaluated the simulation with a user survey. The survey is included as survey.pdf.
| Layer | Tools |
|---|---|
| Rendering | Three.js, glTF models with Draco compression |
| Driving AI | YUKA steering behaviours |
| Strategy AI | Brain.js neural network, trained offline in Node.js |
| Build and hosting | Vite, Vercel |
git clone https://github.com/KaloyanG17/Simulated-Motorsport.git
cd Simulated-Motorsport
npm install
npx viteDesigned and built by Kaloyan Gaydarov · LinkedIn
