📱 Building Clients with Shoehive
This section provides documentation and guides for developers creating client applications that connect to Shoehive game servers. Whether you’re building web, mobile, or desktop clients, these guides will help you understand how to properly implement client-side functionality to communicate with your Shoehive game servers.
Overview
Shoehive uses WebSockets for real-time communication between clients and the game server. The client-server protocol is message-based, with standardized formats for different types of operations. This architecture allows for:
- Real-time updates and events
- Consistent state management
- Cross-platform compatibility
- Scalable multiplayer experiences
📚 Documentation Structure
The client-building documentation is organized into the following sections:
- Connecting to a Game Server - How to establish and maintain a WebSocket connection
- Native Commands - Reference for built-in commands to control lobbies, tables, and players
- Receiving Messages - How to process messages and updates from the server
- React Client - A React library that provides an extensible base client hook for real-time communication with Shoehive game servers.
🚀 Getting Started
Before diving into client implementation, ensure you have:
- A running Shoehive game server
- Understanding of WebSocket communication
- Familiarity with your chosen client platform (Web, Mobile, etc.)
⚛ React Client
Shoehive provides a React client library that simplifies the process of building a client application. It is built on top of the WebSocket protocol and provides a simple, flexible WebSocket-based client with React integration for building multiplayer web games. and supports the following features:
- Connection management
- Lobby state management
- Table state management
- Player state management
- Command sending
- Event handling