ESSENTIAL GUIDE TO CREATING MULTIPLAYER GAMES WITH GODOT 4.0 harness the power of Godot Engine's GDScript network API to connect players in multiplayer games
Level up your Godot 4 networking skills with this comprehensive guide featuring dedicated servers and persistent worlds, illustrated with key images in color Key Features Ensure player synchronization and coexistence in a game world Mitigate latency in your multiplayer games to design a seamless sha...
Otros Autores: | , |
---|---|
Formato: | Libro electrónico |
Idioma: | Inglés |
Publicado: |
Birmingham, UK :
Packt Publishing Ltd
2023.
|
Edición: | 1st edition |
Materias: | |
Ver en Biblioteca Universitat Ramon Llull: | https://discovery.url.edu/permalink/34CSUC_URL/1im36ta/alma991009804922906719 |
Tabla de Contenidos:
- Cover
- Title Page
- Copyright and Credits
- Dedications
- Foreword
- Contributors
- Table of Contents
- Preface
- Part 1: Handshaking and Networking
- Chapter 1: Setting up a Server
- Technical requirements
- Introduction to a network
- Understanding the ENetMultiplayerPeer class
- What is the ENet library?
- What is the UDP protocol?
- How does this connection happen?
- Creating the server
- Creating the client
- Testing our handshake
- Summary
- Chapter 2: Sending and Receiving Data
- Technical requirements
- Understanding packets
- Introduction to the JSON format
- Serialization
- Sending packets with PacketPeerUDP
- Creating an AuthenticationCredentials Autoload
- Sending players' credentials
- Listening to packets with UDPServer
- Authenticating the player
- Loading a fake database
- Replying to the authentication request
- Maintaining the player's session
- Loading the player's avatar
- Summary
- Chapter 3: Making a Lobby to Gather Players Together
- Technical requirements
- Calling functions remotely with RPCs
- Introducing the @rpc annotation
- What's necessary for an RPC?
- Understanding the multiplayer authority
- Comparing UDP and ENet approaches
- Remaking the login screen with RPCs
- Establishing an ENetMultiplayerPeer connection
- Creating the RPC functions template
- Authenticating the player
- Adding the player's avatar
- Cleaning AvatarCards
- Retrieving players' avatars
- Testing the lobby
- Summary
- Chapter 4: Creating an Online Chat
- Technical requirements
- Understanding data exchange and channels
- Reliable and unreliable packets
- Understanding channels
- Sending chat messages
- Updating peer's data remotely
- Summary
- Part 2: Creating Online Multiplayer Mechanics
- Chapter 5: Making an Online Quiz Game
- Introducing the online quiz game.
- Setting up a lobby for the quiz game
- Displaying new players
- Starting the match
- Implementing online turns
- Updating players about the round
- Turning local mechanics into remote gameplay
- Understanding the questions database
- Loading and updating questions
- Sending players' answers to the server
- Summary
- Chapter 6: Building an Online Checkers Game
- Technical requirements
- Introducing the Checkers project
- Understanding the Checkers Piece scene
- Comprehending the FreeCell scene
- Introducing the CheckerBoard scene
- Serializing players' turns
- Working with MultiplayerSynchronizer
- Updating and syncing the CheckerBoard
- Handling remote turn shifts
- Setting up players' teams
- Enabling and disabling team pieces
- Managing win and lose conditions
- Summary
- Chapter 7: Developing an Online Pong Game
- Technical requirements
- Introducing the Pong project
- How the player paddles work
- Understanding the Ball scene
- Managing players' scores
- Tying everything together
- Setting up online multiplayer paddles
- Changing the paddle's owner
- Assigning the players' paddles
- Syncing remote objects
- Updating the ball's position
- Coordinating the paddle's position
- Summary
- Chapter 8: Creating an Online Co-op Platformer Prototype
- Technical requirements
- Introducing the platformer project
- Understanding the Player class
- Unveiling the Crate class
- How the InteractiveArea2D class works
- Understanding the PlayerSpawner class
- Spawning players in the match
- Giving players control in PlayerSpawner
- Setting up the Player multiplayer controls
- Syncing physical objects
- Synchronizing the player's position and animations
- Updating the crate's position remotely
- Summary
- Chapter 9: Creating an Online Adventure Prototype
- Technical requirements
- Introducing the prototype.
- Understanding the Player scene
- Gauging the Asteroid scene
- Unraveling the quest system
- Breaking down the World scene
- Logging the player in to the server
- Authenticating players
- Syncing the World scenes
- Separating server and client responsibilities
- Shooting bullets on all instances
- Calculating an asteroid's damage
- Storing and retrieving data on the server
- Implementing the quest system's client side
- Implementing the quest system's server side
- Summary
- Part 3: Optimizing the Online Experience
- Chapter 10: Debugging and Profiling the Network
- Technical requirements
- Introducing Godot's Debugger
- Mastering the Stack Trace tab
- Debugging with the Errors tab
- Exploring the Profiler tab
- Exploring the Visual Profiler tab
- Exploring the Monitors tab
- Getting to know the Video RAM tab
- Grasping the Misc tab
- Understanding the Network Profiler
- Identifying the project's bottlenecks
- Using the Network Profiler
- Using the Monitors tab
- Summary
- Chapter 11: Optimizing Data Requests
- Technical requirements
- Understanding network resources
- Decreasing the requests count
- Reducing the weapon fire count
- Decreasing Asteroid's syncing count
- Compressing data with the ENetConnection class
- Summary
- Chapter 12: Implementing Lag Compensation
- Technical requirements
- Introducing lag issues
- Dealing with unreliable packets
- Common compensation techniques
- Implementing server-side motion
- Bridging the gaps with interpolation
- Playing ahead with prediction
- Gazing into the future with extrapolation
- Summary
- Chapter 13: Caching Data to Decrease Bandwidth
- Technical requirements
- Understanding caching
- Setting up the HTTPRequest node
- Understanding the HTTP protocol
- Setting up the scenes and database
- Implementing texture caching.
- Implementing database caching
- Going further with caching
- Summary
- Index
- Other Books You May Enjoy.