Game Gen - Week 37

Multiplayer Games!

This week I have been continuing to improve my knowledge of systems in Unreal Engine by starting on a blueprint-based multiplayer game. I took a "paws" on Star Paws because I encountered so many bugs that I decided to continue in C++ a bit later. For now, I want to focus on blueprinting and expanding my knowledge there as it translates well for me into C++ when I learn new functionality in code. 

Current Project: Multiplayer Horror

I want to put all of the skills I have acquired thus far into the challenging but achievable goal of creating a multiplayer game that I can release on Steam. This puts a lot of my skills to the test and pushes me toward a goal that really motivates me and is more achievable at my current skill level. Here are some of the things I've done so far for this project: 

Video Overview: 



Multiplayer Replicated Blueprints

Player Interaction with Blueprint Interface

This blueprint is the functionality that was implemented to allow the player to pick up objects in front of them. It uses a line trace to find the object in front of the player and then handles whether the player has authority or not as either the Host of the game or a joining Client. 

If the player is a client and thus does not have authority, we have to provide authority by passing the actions through custom events which set the replication for the events. Once we have the proper authority, we call the Interact blueprint interface function which is implemented on any interactable item. 



Multiplayer Flashlight Functionality

For the flashlight, we need to ensure that the players can all equip the flashlight, that it is visibly equipped to other players, and that they can turn the light on and off. For this, we mainly focused on providing authority for calling of the blueprint functions within the Flashlight itself, like turning it on or off. To allow other players to see the flashlight in their friend's hands, we enabled replication on the components that we wanted to show, such as the flashlight's mesh and light. 



Replicated Sprinting

Sprinting was the first replication we started with and is a great way to understand what is going on. Simply put, when hosting a multiplayer game, only the host of the game who started the server automatically has the authority to do anything that is not directly on the player's own computer. For example, without replicating sprinting, first, the client players who joined the host's game couldn't sprint at all, then other players wouldn't see them sprinting, so we must pass authority down the chain to allow everyone to sprint and see each other sprint as well. 



Interactable Pickup Parent BP

The parent of the interactable pickups is pretty simple. It holds the majority of replication for one, including ensuring the Static Mesh and other components are replicated in the children of this actor. It also sets up the main visible indications that it is an interactable object. Temporarily, this involves turning on a light and a Text component. 



Interaction Implementation in Child BP

Because we are using a Blueprint Interface, it makes it much easier to then just implementing interface functions inside the blueprints to prevent calling different functions from the player for every interactable item. Now, they all use this "Interact" event with custom functionality related to the specific object the player is interacting with. 




Blender Modeling

I've also made a couple of Blender Models for this game so far, which I'm excited to dive back into Blender a bit and make some of the models for different props and environment objects. So far, I've made a Flashlight, a Trashcan, and a Orbitz bottle (Anyone remember those drinks?) which in my game will be called "Zorbitz".

Here are the meshes I've made:


Simple Trash Can by zachmckinnon on Sketchfab


Overall I've been enjoying making the different mechanics, models, and hopefully some custom materials and other cool enhancements I can create for the game's immersive experience.\

Level Design for David: 

I have also continued to work with David on the level design for his game. While this has been a unique challenge, it has been a great learning experience so far! I worked more on sketches this time so we could iterate on the ideas before I started working on them in the Engine. 
The most valuable learning experiences working on this level of design have been working with people with differences in communication style from mine and working on crossing the bridge of communication to understand the requirements and ideas of the designer while still allowing for creative freedom and continual improvement on the design. 

Sketch of one area (Floor 2 in the below drawing) to better show the concept. 

Level Map Sketch to iterate on ideas for the way the player unlocks each skill in the tutorial level.


Next two-week goals:

  1. Implement the Inventory for Players. 
  2. Create a material to highlight interactable objects rather than a light. 
  3. Create Widgets for Interactions to show players. 
  4. Continue to work with David on Level Design



Comments

Popular posts from this blog

Game Gen - Week 19

Game Gen - Week 1

Game Gen - Week 4