top of page

Grey Box & Blueprinting Puzzle 1


After completing the SketchUp designs, I then began to build a grey box version of the level in Unreal. Once the grey box levels had been completed (one for the stage and one for the cupboard) I then began to add blueprints into each level.

My first blueprints were very simple, level transitions for when the player walked into the cupboard. These were Box Collisions in the Level Blueprints that when the player collided with loaded the alternate level (collision on stage loads the cupboard and vice versa)

Once these had been completed and tested, I then moved onto more complex mechanics. The next blueprint I began was for opening a drawer so the player could retrieve a key to open a chest. To do this I created a timeline for the animation, using variables to set the initial states and then adding collision around the drawer so that when the player pressed a button (currently E) in the collision the drawer would open, revealing a key that would automatically be added to the player's inventory - which is a boolean variable called HasKey? There were several problems in animating the drawer, mainly using the wrong axis so the drawer started floating above the chest, and errors with collisions being able to work. However I resolved these and it works.

The next blueprint was then a very similar one for opening the chest. It began with a Begin Overlap for the Box Collision, and linked to an Enable Input, getting the Player Controller. It the Opened a Gate, with the keyboard button E being used to Enter the Gate. It then cast to the First Person Character, branching with a condition of having the Key from the Drawer Blueprint, if the player did not have a key it would print a prompt telling the player they needed the key. If they did have the key, it would then use a Timeline to play an animation using a Rotator and the Set Actor Relative Rotation functions to rotate the lid on it's hinge open. It would then set off a delay for 2 seconds so the player could see the Wand in the chest, before Destroying the Component and printing a message telling the player that they Wand had been added to their inventory. To add this to the player's inventory, it set a boolean from the First Person Character called HasKey? to true.

Once I had completed the basic blueprints, I began to add some extra user interface design into the game. To do this, I added a text prompt that told the user which key to press to interact with an object. This will be added into all future interactions and has been added to the two previous. The blueprint for this began by getting the player controller and the HUD and casting this into the FirstPersonHUD. I also had a variable for setting the text to display and these were set and plugged into the cast. After this, I used a Draw Text to Screen and plugged the Text variable in. This displayed a message when the player entered a Collision Box.

My next task will be to set up the Blueprints for the second puzzle: getting the Rabbit.

Featured Posts
Recent Posts
Archive
Search By Tags
No tags yet.
bottom of page