Whilst this has proved to be helpful when creating the level, I don't want the player to be exploring the environment with that ugly gun taking up a portion of screen space:
This is me in control of the built-in first person blueprint.
For my major project I have chosen to create a blank project. This is the first time I have actually tried this option as I usually rely on the pre-existing blueprints. To my annoyance the blank project lets you fly around freely when you hit the play button, which is obviously not ideal:
This is me flying around the level in the blank project.
I find it a little annoying that Unreal Engine doesn't just have a simple first person blueprint (minus the gun), but I have chosen to use this as a learning excercise. I will create my own first person blueprint, and document its creation below.
I started by looking online for a simple tutorial explaining what I was after, and found this video:
Despite the somewhat amateurish quality this video was rather insightful. It introduced me to some options hidden away in the settings tab that I wasn't aware of such as inputs and key binding which tells the engine how you want to control the character as you play.
Accessing the project settings window.
It was here that I found you can simple enter movement the types of movement you want your character to have:
My custom movements with keyboard mapping.
With the custom inputs set up correctly, I created a new blueprint which would be able to execute these commands whenever I entered the desired key:
Newly created blueprints. The BP_Character is what the player will control.
My knowledge of blueprints is still rather limited and I consider myself more of a visual artist than a technical one, however this was a simple setup even for me. You can see below the how I have hooked up the inputs I created within the project settings to actions that will tell the engine how I want the player to move. I have included simple movements for going left, right, forwards and backwards. As well as mouse movement for looking around, and also the ability to jump:
My first person character blueprint.
I did encounter some problems initially. Despite following along with the tutorial on Youtube, I couldn't get the first person blueprint to work. I decided to cross reference my scene with a new scene using the default first person blueprint. After studying it I found that the tutorial left out some important information! You not only need to have the first person blueprint placed somewhere within your scene, you also need to make sure an option to control said blueprint is enabled:
Enabling the option that allows you to control the first person blueprint.
With these options enabled I was successfully able to control the camera in first person! This will prove helpful when I want to check the scale of objects in the environment, but also I feel more confident when experimenting with the project settings which is something I normally avoid.
Successful control of the first person blueprint.
Now I can focus on creating the environment without the annoying gun blocking the screen!
No comments:
Post a Comment