Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Unreal Engine 4.X By Example

You're reading from   Unreal Engine 4.X By Example An example-based practical guide to get you up and running with Unreal Engine 4.X

Arrow left icon
Product type Paperback
Published in Jul 2016
Publisher Packt
ISBN-13 9781785885532
Length 506 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Benjamin Carnall Benjamin Carnall
Author Profile Icon Benjamin Carnall
Benjamin Carnall
Arrow right icon
View More author details
Toc

Table of Contents (12) Chapters Close

Preface 1. Introduction to Unreal Engine 4 FREE CHAPTER 2. Blueprints and Barrels – Your First Game 3. Advanced Blueprint, Animation, and Sound 4. Unreal Engine, C++, and You 5. Upgrade Activated – Making Bounty Dash with C++ 6. Power Ups for Your Character, Power Ups for the User 7. Boss Mode Activated – Unreal Robots 8. Advanced AI and Unreal Rendering 9. Creating a Networked Shooter 10. Goodbyes and Thank yous Index

Starting the networked First Person Shooter


Ok, now that we have covered the basics, let's put this information to use and begin work on our network shooter project!

Preparing the NS project

The first thing we need to do is remove a few things that have been provided to us by default in the project. We are going to be removing code from a few of the objects and adding some of our own. I will run through this very quickly, as any significant code changes will be described later in the project. First, navigate to NS.h and change #include "EngineMinimal.h" to #include "Engine.h".

Next, navigate to NSGameMode.h and add the following enum above the ANSGameMode class definition:

UENUM(BlueprintType)
enum class ETeam : uint8
{
    BLUE_TEAM,
    RED_TEAM
};

Here we have a classed enum that will represent the two teams that feature in the NS project. The enum has been classed to be of type uint8. Now that we have this in place, let's work with our ANSCharacter object. We are going to be removing quite...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image