🏎️ MakeCode Arcade Racing Physics Tech Demo | Custom Brush Tire Model, Weight Transfer, Suspension & Damage

Hey everyone! I wanted to share a racing physics tech demo I’ve been working on in Microsoft MakeCode Arcade.

This project is still a work in progress and has not reached version 1.0 yet. I’ve been working on it for a long time and have put a tremendous amount of time and effort into getting the physics and other systems working. This is also why I haven’t made a post in about a year. I’ve been focused on developing the project rather than posting updates, and I wanted to make meaningful progress before sharing what I’ve been building.

The car is currently being modeled after a 2025 Ford Mustang GTD, and I’m trying to make the underlying vehicle physics as realistic as possible within MakeCode Arcade’s limitations.

:chequered_flag: Track and 3D Rendering

  • The track is currently being modeled after Watkins Glen International.

  • The project uses a 3D raycasting extension with floor and ceiling rendering.

  • I’m working on improving the track itself before moving on to other visual details.

:wheel: Custom Brush-Style Tire Physics

One of the biggest parts of this project is a custom tire-force model. Instead of relying on a basic arcade-style grip system, I’ve built a brush-style tire model designed to make the tires behave more realistically.

The tire system includes:

  • Longitudinal slip ratio for acceleration and braking.

  • Lateral slip angle for cornering.

  • A brush-style force curve to model how tire forces develop.

  • A combined-grip system that accounts for the tires producing longitudinal and lateral forces simultaneously.

  • A friction envelope that limits the total force a tire can produce.

  • Load sensitivity, so grip does not increase linearly with tire load.

  • Transient tire response and relaxation.

  • Speed-dependent behavior affecting rear-tire grip and power oversteer.

The goal is to make the car respond naturally to throttle, braking, steering, weight transfer, and loss of traction rather than relying on scripted outcomes.

:thermometer: Tire Temperature, Wear, and Pressure

The tire system also includes tire heat, wear, and pressure.

These systems are intended to make tire condition an important part of driving, rather than having the tires provide exactly the same performance indefinitely.

Tire behavior is connected to the overall physics model, and I want to continue refining how these systems affect grip and vehicle handling.

:racing_car: Full Vehicle Drivetrain and Mechanical Systems

The vehicle is being developed around a full drivetrain assembly, with multiple mechanical systems working together to control how power reaches the road.

The systems include:

  • Engine torque: The engine produces torque that feeds into the drivetrain.

  • Drivetrain assembly: A connected powertrain system for transferring engine power to the driven wheels.

  • Transmission: Gear selection and shifting affect how the vehicle delivers power.

  • Differential system: The differential is part of the drivetrain’s power-delivery and wheel-behavior simulation.

  • Brake system: Braking is modeled as part of the vehicle physics, rather than simply applying a generic slowing effect.

  • Traction control (TC): Helps manage wheelspin.

  • Anti-lock braking system (ABS): Helps manage wheel lockup during braking.

  • Automatic shifting: An optional driving assistance feature.

The goal is to have these systems interact with the tire model, suspension, and vehicle dynamics instead of treating each system as an isolated effect.

:seedling: Different Surface Types and Grip

The project also includes different surface types with different grip characteristics.

Current surface types include:

  • Asphalt

  • Track surface

  • Grass

The purpose is to make the car behave differently depending on what its tires are contacting. Driving on grass should not feel the same as driving on the racing surface, and leaving the track should have meaningful consequences for traction and control.

:hammer_and_wrench: Suspension and Weight Transfer

The car has a suspension model that includes:

  • Spring forces.

  • Compression and rebound damping.

  • Bump stops.

  • Maximum suspension travel.

  • A simplified suspension response based on load and estimated compression.

Weight transfer is also part of the vehicle’s handling behavior, influencing how the car responds under acceleration, braking, and cornering.

The suspension is still an approximation rather than a complete vertical rigid-body chassis simulation, so this is an area I may continue improving as the project develops.

One of my goals is to make the driving assists account for weight transfer properly instead of having them behave as though the vehicle’s load distribution never changes.

:collision: Vehicle Damage

The project also includes a vehicle damage system. Damage is intended to add consequences to crashes and other incidents instead of allowing the car to behave identically regardless of what happens.

This is another system that can be refined as the rest of the vehicle physics develops.

:gear: Driving Assists and Controls

The project includes several driving options and assistance systems, including:

  • Traction control.

  • ABS.

  • Stability control.

  • Automatic shifting.

  • Manual shifting.

Manual shifting procedure

To shift manually:

  1. Release the gas.

  2. Hold Shift.

  3. Press Up Arrow to upshift or Down Arrow to downshift.

  4. Release the arrow key.

  5. Release Shift.

  6. Apply the gas again, or brake as needed.

The intention is to make manual shifting a deliberate action rather than an automatic gear change.

:clipboard: Main Menu, Settings, and Vehicle Selector

The project also has a main menu with a Settings menu and a Vehicle Selector interface.

  • The main menu can be opened using the menu button.

  • Audio settings: The first two audio settings at the top of the Settings menu are currently functional. There are two additional audio settings directly below them, but those two are not functional yet. You can adjust the audio settings using the Left and Right Arrow keys to change their values.

  • Driving assists: Below the four audio settings are the driving-assist options. These do work. Move the selector over a driving assist and press A to turn that assist on or off.

  • Vehicle Selector: The interface exists, but no vehicles have been added to the selection list yet.

The current vehicle being developed is the 2025 Mustang GTD, and the selector is part of the groundwork for expanding the project later.

:construction: Current Development Status

This is still a tech demo, not a finished game. The main priority is getting the physics and track into a good state before expanding the project further.

I’ve been putting a lot of time into this project over a long period, which is why I haven’t posted an update in roughly a year. A lot of the work has gone into developing the custom tire model, connecting the different vehicle systems, and trying to make everything work together within MakeCode Arcade’s limitations.

Some systems are more developed than others, and I don’t consider every part of the simulation fully calibrated yet. I’m particularly interested in finding issues with the tire model, suspension, weight transfer, drivetrain, braking, and driving assists before calling the project version 1.0.

:speech_balloon: Feedback Would Be Appreciated!

I’d appreciate feedback from anyone familiar with racing-game physics, vehicle simulation, or MakeCode Arcade development.

Some areas I’d especially like feedback on:

  • The custom brush-style tire model.

  • Combined tire grip and slip behavior.

  • Suspension and weight-transfer behavior.

  • The drivetrain, engine torque, differential, and braking systems.

  • Tire temperature, wear, and pressure.

  • Differences in grip between asphalt, the track surface, and grass.

  • Traction control, ABS, and stability control.

  • Performance optimizations and possible bugs.

  • Ideas for making the simulation more realistic within MakeCode Arcade’s limitations.

I’m trying to build the most physically grounded racing simulation I reasonably can in this environment, so constructive criticism and technical suggestions are welcome!

I’ve put a lot of work into getting this far, and I’m looking forward to continuing development and improving the project as I work toward version 1.0.

Thanks for checking out the project! :chequered_flag:

7 Likes

i suspect this is ai

1 Like

Update im currently working on a tutorial mode to teach non experienced drivers how to drive

1 Like

I will tell you the discription for this post was made by ai and i told ai to got through my code and add comments to everything so its clear what it does but i dud not have it edit my code in any way mark my words i can understand why you think this but let me ask you this if it were ai it would have made it instantly not take a year i appreciate your concern i dont like ai for coding either it takes away creativity but i do think its fine for what i did

1 Like

even if this is ai cool idea dude!

1 Like

I promise you this is not ai my freind who found my account was trying to sabatage me and thanks man for actually appreciating my work

1 Like

all good because even I use ai somtimes but only to make a prototype of something i have never don’t before to learn from it but i never use it in the real game it all depends on how you use ai if you use it as a tool thats fine but as your coder thats also ok if you make sure to say its ai

Update:

Made a few changes and improvements to the game:

  • Removed the two audio settings that weren’t doing anything.

  • Added a new driving assist called High-Speed Steering Reduction.

  • Fixed a few issues with the gear shifting and 8-speed drivetrain.

  • Corrected the engine torque from 1,500 Nm to 900 Nm to better match the real Mustang GTD.

  • Added the first part of the driving tutorial system, which teaches launch control and manual shifting.

The tutorial is split into three sections:

  1. Traction control ON and auto shifting ON.

  2. Traction control OFF and auto shifting ON.

  3. Traction control OFF and auto shifting OFF.

More tutorial content will be added as development continues.

I like the game itself and sucks your friend was trying to sabatage. I was just worried because AI games not cool as games are about expressing your personality and such and Ai kinda stops that but cool game and good job for coding it by yourself

1 Like

Thanks man im currently working on the next update with a couple of tuned variables for even more realism and some quality of life features after that update i plan to finish the turorial mode

1 Like

That makes sense, I thought it was a bit weird that 2 users first (and only posts) were on this topic, calling it out for being AI. Nevertheless, it’s a great game, and I appreciate the fact that you admitted you used AI. Not everyone does!

Update: New Features and Improvements

I’ve added a few new features and made some improvements to the physics.

  • Adjustable Driving Assists: Driving assists can now be adjusted from 0 to 100 in increments of 10 instead of just being on or off. This lets you choose how much assistance you want while driving.

  • Damage Reset: Pressing the R key on your keyboard now resets all vehicle damage without having to restart the game.

  • Rectangular Collision Box: Added a rectangular collision system so the car interacts with walls based on its actual shape instead of acting like a cylinder.

  • Grass Resistance: Added resistance when driving through grass. The car now slows down much faster and has a harder time accelerating and turning while off the track.

  • Physics Variable Adjustments: Changed several variables to make the simulation more realistic, including how quickly tire wear builds up, how quickly the engine can blow, how heat transfers into the engine, and other related systems.

More improvements coming soon!

Update:

  • Adjusted the grass resistance to make it more realistic. The car can still accelerate through grass, but it now has more resistance when sliding sideways.
  • Adjusted how tire wear and tire heat are affected by grass to make them more realistic compared to driving on asphalt.

My next update will focus on finishing the tutorial mode, or at least getting the next section completed.

This last update that I released has been pending for a couple of days now, but I’m currently working on a major update with the next section of the tutorial, which is the breaking module and I’m also working on another driving assist the racing line and I’ll have racing light off in the settings, racing line breaking only in the settings, which is just BO and then racing line Full in the settings and since I have a 3-D render 3-D Ray casting extension, I will have to make my own custom render for the driving line and try to make them as close as possible because the 3-D rate casting extension itself is locked and I cannot edit it so I will just have to make my own custom render specifically for the driving line and optimize it as much as possible and just make sure it’s compatible

  • In this update I changed a couple of variables to make the driving a little more realistic.

  • I added another driving assist called the racing line. There are 3 modes in the settings: Off, BO (braking only), and Full (shows both gas and brake). It basically tells you where you need to go on the track.

  • The racing line uses my own custom rendering system that I built on top of the 3D raycasting extension. It doesn’t use the extension’s rendering system, but it is compatible with it.

  • I also added a start-finish line and a lap counter.

  • I finished the braking section of the tutorial.

  • In the next update I’m planning to add a constant cornering tutorial section.

The code is genuinely impressive. Been meaning to ask this: Why did you declare the PI constant rather than using the built-in Math.PI?

2 Likes

Also thanks for appreciating my work

1 Like

I’m currently working on making an autonomous driving mode where I have trained a set of rules into the code where if you press this mode, the car will drive itself around the track currently I’m dealing with issues like the car doesn’t have enough reaction time. It’s running a little bit wide in the corners and it spins out in certain areas but that’s currently what I’m working on. Also, I’m now using a spline instead of just points around the track so hopefully that should make the AI better and also it’s surrendered in a line now so the driving line doesn’t look chunky now it’s a smooth curve.

1 Like

I didn’t know pi was a built-in piece of math and make code arcade

1 Like

15 digits of pi for it is crazy that’s like nasa level