SlideShare a Scribd company logo
1 of 18
Download to read offline
1. The Project
2. The Local Network
3. Spawn Points
4. Local Players
5. Syncing Transforms
6. The Network Manager
7. Shooting
8. Networked Shooting
9. Match Making
10. Adding a Nice Lobby
11. The Lobby Hook
12. Player Health
13. Deathmatch
1. Open Project
2. Open the scene StartingScene
3. Drag in Tank prefab
4. Apply TankController script
5. Save scene as MainGameplay
6. Test scene
7. Stop the play button
1. Create empty GO and name it NetworkManager
1. Add component: Network Manager (not lobby!)
2. Add component: Network Manager HUD
3. Add NetworkIdentity to the Tank prefab
4. Add Tank prefab to spawn info
2. Build and Test for the craziness
1. Create empty object and rename to Spawnpoint
2. Add component: Network Start Position
3. Duplicated 2 or 3 times
4. Set: Player Spawn Method to Round Robin in the Network Manager
5. Build & Run
1. Active: Local Player Authority on the Network Identity of the Tank.
2. Replace the script TankController with TankController_Net which adds:
• Using UnityEngine.Networking
• NetworkBehaviour
• isLocalPlayer
1. Add Network Transform component to the Tank.
2. Rotation Axis to: Y (top-down 2D)
3. Interpolate Rotation Factor: 15
1. Replace the NetworkManager script with the
NetworkManager_CameraControl script
2. Drag and drop the main camera in the open variable: Scene Camera
1. Add an empty GO named GunBarrel to the Tank prefab and align with gun
2. Add TankShooting script to tank prefab
3. Add Shell prefab to the Shell Prefab property on the TankShooting script
4. Add the ShellController script to the Shell prefab
1. Replace the TankShooting script with the TankShooting_Net version
2. Add a NetworkIdentity component to the Shell
3. Replace the ShellController script with the ShellController_Net version on the
Shell
4. Add the Shell prefab to the Spawnable Objects list on the Network Manager
5. Add a NetworkTransform to the Shell prefab
1. Remove the Tank and Network Manager from your scene.
2. Save the scene as Gameplay_Matchmaking
3. Create new scene: Lobby. (save)
4. Add Lobby and Gameplay_Matchmaking to Build Settings
1. Create empty GO and rename it to Network Manager
2. Add Network Lobby Manager and Network Manager HUD components
3. Create empty GO, add component Network Lobby Player, make prefab and
delete it from the scene.
4. Fill in the Lobby Scene, Play Scene, Lobby Player, and Game Player fields
5. Add the Shell to Registered Spawn-able Prefab
6. Set Player Spawn method to: Round Robin
1. Set up the service in through the Cloud Dashboard
1. Open scene : NetworkLobby
2. In build settings switch Lobby scene for NetworkLobby
3. Select the LobbyManager
4. Fill in: Play scene and Game Player Prefab
5. Add Shell prefab to the Registered Spawnable Prefabs
6. Change Player Spawn Method to Round Robin
7. Remove the NetworkLobbyHook script on LobbyManager
1. Add the TankColor script to the Tank prefab
2. Add the script TankColor_Hook to the Lobby Manager
3. Comment and uncomment the SyncVar attribute in the TankColor script to
see the effect
1. Add script TankHealth to the Tank prefab
2. In the scene Gameplay_MatchMaking add UI-> Canvas, then add UI-> text
3. Remove the text value.
4. On the ShellController_Net script (on the Shell prefab), check Can Kill
1. Inspect the DeathMatchManager script
2. Replace the TankHealth script on the Tank prefab with the TankHealth_DM
script
3. Check Is Deathmatch property of the ShellController_Net script on the Shell
prefab
Thank you
<Survey Link>

More Related Content

Similar to Unity Korea_Unity Day_Multiplayer

Spark local-cloud-on-raspberry-pi
Spark local-cloud-on-raspberry-piSpark local-cloud-on-raspberry-pi
Spark local-cloud-on-raspberry-pi
Pavel Tokarev
 
OpenWRT manual
OpenWRT manualOpenWRT manual
OpenWRT manual
fosk
 

Similar to Unity Korea_Unity Day_Multiplayer (20)

A complete guide to Node.js
A complete guide to Node.jsA complete guide to Node.js
A complete guide to Node.js
 
Akmal Khaleeq Waheed - Challenge 3
Akmal Khaleeq Waheed - Challenge 3Akmal Khaleeq Waheed - Challenge 3
Akmal Khaleeq Waheed - Challenge 3
 
Migrating dhcp from windows server 2003 to 2012 r2
Migrating dhcp from windows server 2003 to 2012 r2Migrating dhcp from windows server 2003 to 2012 r2
Migrating dhcp from windows server 2003 to 2012 r2
 
EnterpriseLogManagement.pdf
EnterpriseLogManagement.pdfEnterpriseLogManagement.pdf
EnterpriseLogManagement.pdf
 
Cloud gaming infrastructure in cloudretro.io
Cloud gaming infrastructure in cloudretro.ioCloud gaming infrastructure in cloudretro.io
Cloud gaming infrastructure in cloudretro.io
 
Tools for developing Android Games
 Tools for developing Android Games Tools for developing Android Games
Tools for developing Android Games
 
How To Build and Run Node Apps with Docker and Compose
How To Build and Run Node Apps with Docker and ComposeHow To Build and Run Node Apps with Docker and Compose
How To Build and Run Node Apps with Docker and Compose
 
Dhcp server and windows 2012
Dhcp server and windows 2012Dhcp server and windows 2012
Dhcp server and windows 2012
 
Docker on openstack by OpenSource Consulting
Docker on openstack by OpenSource ConsultingDocker on openstack by OpenSource Consulting
Docker on openstack by OpenSource Consulting
 
Spark local-cloud-on-raspberry-pi
Spark local-cloud-on-raspberry-piSpark local-cloud-on-raspberry-pi
Spark local-cloud-on-raspberry-pi
 
Install Oracle 12c Golden Gate On Oracle Linux
Install Oracle 12c Golden Gate On Oracle LinuxInstall Oracle 12c Golden Gate On Oracle Linux
Install Oracle 12c Golden Gate On Oracle Linux
 
Codeigniter
CodeigniterCodeigniter
Codeigniter
 
Coding GRIN GLOBAL Wizards
Coding GRIN GLOBAL WizardsCoding GRIN GLOBAL Wizards
Coding GRIN GLOBAL Wizards
 
Simran_Kaur
Simran_KaurSimran_Kaur
Simran_Kaur
 
OpenWRT manual
OpenWRT manualOpenWRT manual
OpenWRT manual
 
ASP.NET Core in Action (2018).pdf
ASP.NET Core in Action (2018).pdfASP.NET Core in Action (2018).pdf
ASP.NET Core in Action (2018).pdf
 
Sync data sfdc_heroku_aws
Sync data sfdc_heroku_awsSync data sfdc_heroku_aws
Sync data sfdc_heroku_aws
 
Go live or go home
Go live or go homeGo live or go home
Go live or go home
 
EMC Networker installation Document
EMC Networker installation DocumentEMC Networker installation Document
EMC Networker installation Document
 
Mastering Kubernetes - Basics and Advanced Concepts using Example Project
Mastering Kubernetes - Basics and Advanced Concepts using Example ProjectMastering Kubernetes - Basics and Advanced Concepts using Example Project
Mastering Kubernetes - Basics and Advanced Concepts using Example Project
 

Recently uploaded

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Recently uploaded (20)

Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Cyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdfCyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdf
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 

Unity Korea_Unity Day_Multiplayer

  • 1.
  • 2. 1. The Project 2. The Local Network 3. Spawn Points 4. Local Players 5. Syncing Transforms 6. The Network Manager 7. Shooting 8. Networked Shooting 9. Match Making 10. Adding a Nice Lobby 11. The Lobby Hook 12. Player Health 13. Deathmatch
  • 3. 1. Open Project 2. Open the scene StartingScene 3. Drag in Tank prefab 4. Apply TankController script 5. Save scene as MainGameplay 6. Test scene 7. Stop the play button
  • 4. 1. Create empty GO and name it NetworkManager 1. Add component: Network Manager (not lobby!) 2. Add component: Network Manager HUD 3. Add NetworkIdentity to the Tank prefab 4. Add Tank prefab to spawn info 2. Build and Test for the craziness
  • 5. 1. Create empty object and rename to Spawnpoint 2. Add component: Network Start Position 3. Duplicated 2 or 3 times 4. Set: Player Spawn Method to Round Robin in the Network Manager 5. Build & Run
  • 6. 1. Active: Local Player Authority on the Network Identity of the Tank. 2. Replace the script TankController with TankController_Net which adds: • Using UnityEngine.Networking • NetworkBehaviour • isLocalPlayer
  • 7. 1. Add Network Transform component to the Tank. 2. Rotation Axis to: Y (top-down 2D) 3. Interpolate Rotation Factor: 15
  • 8. 1. Replace the NetworkManager script with the NetworkManager_CameraControl script 2. Drag and drop the main camera in the open variable: Scene Camera
  • 9. 1. Add an empty GO named GunBarrel to the Tank prefab and align with gun 2. Add TankShooting script to tank prefab 3. Add Shell prefab to the Shell Prefab property on the TankShooting script 4. Add the ShellController script to the Shell prefab
  • 10. 1. Replace the TankShooting script with the TankShooting_Net version 2. Add a NetworkIdentity component to the Shell 3. Replace the ShellController script with the ShellController_Net version on the Shell 4. Add the Shell prefab to the Spawnable Objects list on the Network Manager 5. Add a NetworkTransform to the Shell prefab
  • 11. 1. Remove the Tank and Network Manager from your scene. 2. Save the scene as Gameplay_Matchmaking 3. Create new scene: Lobby. (save) 4. Add Lobby and Gameplay_Matchmaking to Build Settings
  • 12. 1. Create empty GO and rename it to Network Manager 2. Add Network Lobby Manager and Network Manager HUD components 3. Create empty GO, add component Network Lobby Player, make prefab and delete it from the scene. 4. Fill in the Lobby Scene, Play Scene, Lobby Player, and Game Player fields 5. Add the Shell to Registered Spawn-able Prefab 6. Set Player Spawn method to: Round Robin
  • 13. 1. Set up the service in through the Cloud Dashboard
  • 14. 1. Open scene : NetworkLobby 2. In build settings switch Lobby scene for NetworkLobby 3. Select the LobbyManager 4. Fill in: Play scene and Game Player Prefab 5. Add Shell prefab to the Registered Spawnable Prefabs 6. Change Player Spawn Method to Round Robin 7. Remove the NetworkLobbyHook script on LobbyManager
  • 15. 1. Add the TankColor script to the Tank prefab 2. Add the script TankColor_Hook to the Lobby Manager 3. Comment and uncomment the SyncVar attribute in the TankColor script to see the effect
  • 16. 1. Add script TankHealth to the Tank prefab 2. In the scene Gameplay_MatchMaking add UI-> Canvas, then add UI-> text 3. Remove the text value. 4. On the ShellController_Net script (on the Shell prefab), check Can Kill
  • 17. 1. Inspect the DeathMatchManager script 2. Replace the TankHealth script on the Tank prefab with the TankHealth_DM script 3. Check Is Deathmatch property of the ShellController_Net script on the Shell prefab