My Portfolio
U.R.U.I

A puzzle 2D platformer with diagetic UI.

Concept

The concept here is to implement all the stats of the game (life,number of collectibles, ennemies count, jump count...) in the game as platforms and doors.
The game is composed of 5 screens with a little puzzle inside each of them.
The project is a focus on the mechanics, how to make a complete game and how to post on itch.io.

iPhone app
            preferences selection screen
iPhone app
            preferences selection screen

Resource management

As you can see in the first level the player's life is used as a platform to access the first corner. This screen shows how a bonus can be picked up to increase the size of the green platform and how a enemy contact can reduce its size.

Difficulty management

It is easy to increase the difficulty modfiying only the allowed jumps. Here you have to use 6 jumps to finish the level. So giving 6 has a zero error margin and giving 7 makes a 1/7 margin.

iPhone app
            preferences selection screen

Tutorial and new features

Each level introduces a new concept, here the player can shoot to make blue elements move. Each feature is color coded.

Mixing elements

As a puzzle game it is easy to mix all elements to create storytelling and increase challenge. You can have a timed part with a limited Resource giving a sense of emergency to the player.
all elements are controlled by Tweeners giving them smooth animations and step by step event triggers.


__________________________________________________________________

....
blockValue = transform.localScale.y / yScaleBase;
.....
private IEnumerator SmoothScaling(int amount)
{
    isAlreadyChanging = true;
    
     if (isPositive)
     {


      float scaleDuration = 1f;
      Vector3 actualScale = transform.localScale;
      float newYScale = Mathf.Max(0.1f,(blockValue * amount));
      Debug.Log(newYScale);
      Vector3 targetScale = new Vector3(transform.localScale.x,
        newYScale , transform.localScale.z);
      Debug.Log(targetScale);
      for (float t = 0; t < 1; t += Time.deltaTime / scaleDuration)
      {
          transform.localScale = Vector3.Lerp(actualScale, 
          targetScale, t);
          yield return null;
      }

         
} else
    {
        
    float scaleDuration = 1f;
    Vector3 actualScale = transform.localScale;
    float newYScale = Mathf.Max(0.1f, (blockValue * amount));
    Debug.Log(newYScale);
    Vector3 targetScale = new Vector3(transform.localScale.x,
    transform.localScale.y + newYScale, transform.localScale.z);

    for (float t = 0; t < 1; t += Time.deltaTime / scaleDuration)
    {
        transform.localScale = Vector3.Lerp(actualScale, 
        targetScale, t);
        yield return null;
    }
    
  }
    
    isAlreadyChanging = false;
}

          

Smooth Scaling function

This method is the base logic for all "interactive" elements of the game (moving platform, bars and list picker). Coupled with a switch to select the right variable to read, the method is triggered by an event system.
The major challenge was to set a limit an growing rate for the platform, the solution is to set the blockvalue for each element is the code throught a init function and a reset funtion (the formula is the first line of the show script). This solution allows the designer to create platforms of the desired transform proportions without breaking the code. The moving platform uses the same logic for the max distance to travel.
The growing bar do not uses a tweener like the moving platform but replicates the same behavior (smooth transformation for X times) with a IEnumerator and a boolean. This code adapts itself to the transform of the attached object. The only constraint left to the designer is to set the pivot point of the object at the desired place.

Upgraded Version

A new version was made for a Game Jam, improving graphics elements and simplifying the code. New mechanics were added like having two lists matching their elements and influencing each other (in this case monsters and platforms) .
The next improvement would be to change the colors to patterns to differenciate the stats.

Itch.io integration

This game was the first I publish on Itch.io to test the website.