Tutorial - Create a Local Co-Op Player Setup Screen in Unity with the New Input System

Tutorial - Create a Local Co-Op Player Setup Screen in Unity with the New Input System

Broken Knights Games

4 года назад

37,568 Просмотров

In this video I demonstrate a pattern which can be used in a game to create a player-join setup screen that is common in most games where local co-op multiplayer is supported. We will be building off of the example from my last video (https://youtu.be/2YhGK-PXz7g) where I add a setup screen and create a system which will persist the player input configuration to span scenes. We will be using components found in the new input system package such as PlayerInputManager, PlayerInput, InputSystemUIInputModule, and MultiplayerEventSystem.

Technology Used
Unity Engine 3D 2019.3
New Unity Input System
Git
Visual Studio 2019
.Net Scripting in C#

Everything shown in the video can be downloaded from my Github repository so you can follow along, or reference my approach to creating a local co-op setup screen and multiplayer system in this project.
Github Repository Link: https://github.com/Srfigie/Unity_NewInputSystem_LocalCo-op
Github Sample Start Link: https://github.com/Srfigie/Unity_NewInputSystem_LocalCo-op/tree/master/Player_Join_Screen_Demo
Github Completed Sample Link: https://github.com/Srfigie/Unity_NewInputSystem_LocalCo-op/tree/master/Player_Join_Screen_CompletedSample

Official Documentation Link: https://docs.unity3d.com/Packages/[email protected]/manual/QuickStartGuide.html

Time Codes:
02:14 Create Setup Menu Scene
03:40 Create a PlayerConfigurationManager Singleton (holds the PlayerInputManager Component)
16:00 Create PlayerConfiguration Prefab (holds the PlayerInput Component)
17:25 Create Individual Player Setup Menu UI Prefab
34:27 Add New Player Action And Generate C# Class
36:24 Spawn Player Setup Menu when player joins
43:50 Update existing scene to load in player configurations from setup screen
56:13 Final Working Result

Broken Knights Games:
Website: https://brokenknights.com
Twitter: https://twitter.com/Broken_Knights
Instagram: https://www.instagram.com/brokenknightsgames/





► Music Credit: LAKEY INSPIRED
Track Name: "Better Days"
Music By: LAKEY INSPIRED @ https://soundcloud.com/lakeyinspired
License for commercial use: Creative Commons Attribution 3.0 Unported "Share Alike" (CC BY-SA 3.0) License.

Тэги:

#Unity3d #Unity #Input_System #New_Input_System #local_co-op
Ссылки и html тэги не поддерживаются


Комментарии: