Paint Me UP! AR Mobile Game Prototype

15/05/2025

Paint Me UP! AR Logo

Concept

This was a prototype game developed for a job interview using Unity.

This is an AR game where you move around to detect the ground, press the button to create a cube, and start the game. You have 180 seconds to find the colours shown in the UI in the real world. Once any correct colour is selected or 30 seconds passes a new one is shown. Every correct color found is painted on one cube face! The phone also has sounds and vibrates according to player actions.

Paint Me UP! AR Cube Painting

Download the Game

Click the link below to download the game APK: Paint Me Up AR Mobile Game

Game Programming

Regarding programming the core strucutre of the game is as follows:

  • ARCubeSpawner.cs is responsible for making sure a plane has been detected and if so enabling the cube placement button. If pressed it then creates a probuilder cube in the scene
  • CubePainter.cs updates the color an a cube face to a new given color by updating the vertex colors of cube face of a probuilder cube mesh
  • GameReset.cs simply reloads the scene on a button pressed (called onClick on the end screen)
  • PaintingManager.cs was the originally created class to handle the core game logic, handling player taps, getting the camera image, analysing the colors and then updating the UI accordingly. It was then later split into four classes.
    • PaintMeUpGameManager.cs - handles the core game logic once a cube has been spawned, including timers and such.
    • PlayerTapHandler.cs handles player taps once the game has begun and calls ColourScanner.cs when a touch is done.
    • ColourScanner.cs handles the conversion from a XRCpuImage into a texture and then into pixels to check for colors either of the whole image to get the 6 most frequent simplified colors (at the game setup) or at the press position of a touch (during the game).
    • GameUIManager.cs handles UI updates and calling on the end screen by listing to the PaintMeUpGameManager.cs.

This was created using the new unity input system, Probuilder (for the cube painting mesh) and using the XR Interaction Toolkit.

The git repository is available here!

Conclusion

This was a great chance to learn how to create an AR game and all the core foundations for any XR games (AR/MR/VR/etc), and gave me a strong want to develop more mixed or augmented reality games in the future!

Once again, if you want to play the game check it out bellow or check out the whole project on GitHub! Paint Me Up AR Mobile Game GitHub Repository