Project Overview

Color Craze is a mobile brain teaser solo project. The player is supposed to press the correct side of the cube, corresponding to the color that the text says. Both the text and the cube sides switch colors to confuse the player!

Game Info

Roles: Game Programmer

Time: 4 Weeks

Date: February 2018 - March 2018

Team Size: Solo project

Genre: Brain Teaser

Engine: Unity

Version Control: None

Code Language: C#

The color switching system

This was the first project I completed and looking back I can clearly see that. A lot could be improved, every color for every side is a gameobject. They switch by being set to disabled or enabled randomly has long as theres only one of each color.

If I were to remake this today I would have one gameobject for each side and switch the sprite colors and a int variable to match the color. That way it would be easier to check that theres always one of each color.


public void cubeclickleft()
{
    if(Leftgreen.active == true && Colortextgreen.active == true)
    {
        // Randomizes the cubes side color
        randomizecubevalue();
        // Randomizes the color that the text says
        randomizecolortextvalue();
        // Randomizes the color that the text is
        randomizetextcolor();
        // Does nothing (was meant to add the fastest click you've made to scoreboard but never implemented
        Averagetime();
        // Sets the timer to the standard value (depends on how much points you have)
        timer = standardtimer;
        // Plays a sound so that the player knows he/she pressed the right side
        Preloadermanager.instance.Dong.Play();
        // Adds a point to the score
        score++;
    }
    else if(Leftgreen.active == true && Colortextgreen.active == false)
    {
        // Adds the last score you had to check if its higher then any of your last 3 highscores
        Preloadermanager.instance.newhighscore = score;
        // Sets the score to show in the "you lost" scene
        Preloadermanager.instance.endscore = score;
        // Loads the "you lost" scene
        SceneManager.LoadScene(3);
    }
    if (Leftred.active == true && Colortextred.active == true)
    {
        randomizecubevalue();
        randomizecolortextvalue();
        randomizetextcolor();
        Averagetime();
        timer = standardtimer;
        Preloadermanager.instance.Dong.Play();
        score++;
    }
    else if (Leftred.active == true && Colortextred.active == false)
    {
        Preloadermanager.instance.newhighscore = score;
        Preloadermanager.instance.endscore = score;
        SceneManager.LoadScene(3);
    }
    if (Leftblue.active == true && Colortextblue.active == true)
    {
        randomizecubevalue();
        randomizecolortextvalue();
        randomizetextcolor();
        Averagetime();
        timer = standardtimer;
        Preloadermanager.instance.Dong.Play();
        score++;
    }
    else if (Leftblue.active == true && Colortextblue.active == false)
    {
        Preloadermanager.instance.newhighscore = score;
        Preloadermanager.instance.endscore = score;
        SceneManager.LoadScene(3);
    }
}
            

The UI

I feel that the UI is a weak part of this game. Since it was a solo project I tried to do a minimal art approach, simple shapes and colors. And while it worked for the actual gameplay parts, The menu is confusing to navigate.

Each menu is a panel with all the buttons being child objects. To switch menu it does the same has with the cube sides. It enables the menu the player want to go to and disables all the others.


//One of the menu switches
public void OpenPlayMenu()
{
    MainPanel.SetActive(false);
    HighscorePanel.SetActive(false);
    SettingsPanel.SetActive(false);
    InfoPanel.SetActive(false);
    GameSelectPanel.SetActive(true);
    HighscorePanelTT.SetActive(false);
    HighscorePanelRE.SetActive(false);
    HighscoreSelectPanel.SetActive(false);
}
//When a player press play normal game button
public void Playgame()
{
    SceneManager.LoadScene(2);
}
        

Not every menu would need to be disabled but I did that because I wanted to be 100% sure no menus overlapped. That resulted in so much unnecessary code and maked it harder to read.

Release

This was also the first game I tried to release on the google play store. I wanted to learn how releasing a game could be and how feedback should be taken in to consideration.

After joining a discord community asking for feedback on the title I changed the background color from a dark gray to a lighter one to make the bright colors of the cube look more pleasing and less straining on the eye.

Old Color

Old_Color

New Color

Old_Color

I also changed how fast the ingame timer changed to a lower max time but that could have been tweaked even more since it was still very slow.