Menu

Monument Valley

Monument Valley is an indie puzzle game developed and published by Ustwo Games. The player leads the princess Ida through mazes of optical illusions and impossible objects while manipulating the world around her to reach various platforms.

GamePlay

In Monument Valley, player-character princess.Ida journeys through mazes of optical illusions and impossible objectswhich are referred to as "sacred geometry" in-game, as she journeys to be forgiven for something.The game is presented in isometric view,and the player interacts with the environment to find hidden passages as Ida progresses to the map's exit.Interactions include moving platforms and pillars, and creating bridges.The player is indirectly cued through the game by design elements like color, and directly cued by crow people, who block Ida's path.

Level Design - Probuilder

ProBuilder is a unique hybrid of 3D modeling and level design tools, optimized for building simple geometry but capable of detailed editing and UV unwrapping too. Use ProBuilder to quickly prototype structures, complex terrain features, vehicles and weapons, or to make custom collision geometry, trigger zones or nav meshes. ProBuilder also takes advantage of Unity’s seamless round-tripping capabilities with digital content-creation tools.

Create a Monument valley Level Design using Probuilder. Use the Camera Angle as Isometric View.

Why Use an Isometric Camera?

I examined several quite popular games to determine what perspective angle they are using. For the purpose I created a grid that is 45 and 60 degrees isometric viewed. None of these grids fit to the game's perspective. So I tried to find the angle that fits best to the perspective and it is close to 53.5 degrees. However, this number seems like coming from nowhere and I believe there is a strong logic behind the number that defines the perspective angle. I tried 9/16 * 90 degrees and 3/4 * 90 degrees (coming from ratios of screens resolution 16:9 and 4:3) but none of my assumptions seem to be correct. The angle in most 2.5D isometric games is 26.565 degrees and is derived very simply by putting 2 pixels horizontally for every 1 pixel vertically to create a tile, so atan(.5) = 26.5650512 deg.


   Public class Walkable...
   {
        public walkpointoffset = 0.4f;
        public stairpointoffset = 0.5f;

        public Vector3 GetWalkPoint()
        {
        float stair = isStair ? stairOffset : 0;
        return transform.position + transform.up * walkPointOffset - transform.up * stair;
        }

         private void OnDrawGizmos()
        {
            Gizmos.color = Color.gray;
            float stair = isStair ? .4f : 0;
            Gizmos.DrawSphere(GetWalkPoint(), .1f);

            if (possiblePaths == null)
                return;

            foreach (WalkPath p in possiblePaths)
            {
                if (p.target == null)
                return;
                Gizmos.color = p.active ? Color.black : Color.clear;
                Gizmos.DrawLine(GetWalkPoint(), p.target.GetComponent().GetWalkPoint());
            }
        }
   }

Attach the code to the every block of the player could move.I created a function to determine the walk point by following some offset variables.

I wanted to create a system where player could determine the possible directions the player could go from a certain object, for that i created a class called WalkPath. That has a Transform variable and a boolean to check the path is activated.


[System.Serializable]
public class WalkPath
{
    public Transform target;
    public bool active = true;
}

Attach this Script Walkable.cs to the every path we need to walk and there will be a Gizmos which shows the path we need to walk and the Stairs and the walk place have different offset.

How the Algorithm works - Custom Pathfinding


The player is in the cube no 1 and the target position is cube no 5. Lets create a 2 array NEXT CUBE and PAST CUBE
As the player is in 1, so we just need to add the cube to the Past cube list. After adding the cube Explore cube function begins and the cube has two possible directions 0 and 1 . First the cube checks the 0 position.

  • Remove the 0 in the next cube.
  • Check for the condition , 0 is the clicked cube and is it in visited cube list.
  • If it is not in visited cube, remove from the current cube list and add to visited cube.
  • Move to Next cube

  • This way check for everycubes till we reach the clicked cube.

    You will get the list of walkable points.