Book Image

Building an RPG with Unreal 4.x

By : Steve Santello
Book Image

Building an RPG with Unreal 4.x

By: Steve Santello

Overview of this book

Now that Unreal Engine 4 has become one of the most cutting edge game engines in the world, developers are looking for the best ways of creating games of any genre in the engine. This book will lay out the foundation of creating a turn-based RPG in Unreal Engine 4.12. The book starts by walking you through creating a turn-based battle system that can hold commands for party members and enemies. You’ll get your hands dirty by creating NPCs such as shop owners, and important mechanics, that make up every RPG such as a currency system, inventory, dialogue, and character statistics. Although this book specifically focuses on the creation of a turn-based RPG, there are a variety of topics that can be utilized when creating many other types of genres. By the end of the book, you will be able to build upon core RPG framework elements to create your own game experience.
Table of Contents (17 chapters)
Building an RPG with Unreal 4.x
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Key binding


We are now going to bind a key to open up the pause menu, and only allow this to happen when the player is not in battle (in other words, the player is out in the field). Since we already have a FieldPlayer set up from the previous chapter, we can easily create actions within our FieldPlayer Blueprint class that will control our pause menu. To start, navigate to Blueprints | Open Blueprint Class… | FieldPlayer:

At this point, we are going to want to have the pause screen pop up when the player presses a key; in this case, we will use P for pause. To do this, we will first need to create a key event that will fire off a set of actions of our choice after a specific key is pressed. To start this key event, right-click on your Event Graph, which will open up all actions that can be associated with this Blueprint, and then navigate to Input | KeyEvents | P:

Once done, this will create a key event for the press and release of P. You will notice that this event has pressed and released...