Multiplayer Card Game
Real-Time Multiplayer • Android • Socket.IO • Firebase-Enabled
Unity
C#
Socket.IO
Node.js
Firebase Auth
FCM Push
Social Invites
Real-Time Multiplayer
State Synchronization
Project Overview
Multiplayer Card Game is a real-time online card game built for Android,
designed to support smooth multiplayer gameplay using a custom
Socket.IO client–server architecture.
The project integrates Firebase Authentication for secure user login,
Firebase Cloud Messaging for real-time notifications, and
social invite flows to improve player engagement and retention.
My Role & Responsibilities
- Designed and implemented real-time multiplayer architecture using Socket.IO
- Built client-side networking layer in Unity (C#)
- Integrated Node.js backend for room management and game state handling
- Implemented turn-based game flow with server-authoritative validation
- Handled player join, disconnect, and reconnection scenarios
- Optimized network message payloads to reduce bandwidth usage
- Ensured fair gameplay by preventing client-side state manipulation
- Integrated Firebase Authentication with Google and social sign-in providers
- Implemented Firebase Cloud Messaging for match invites and game notifications
- Built social invite sharing via WhatsApp and native platform share intents
- Linked authenticated users with multiplayer sessions securely
Engineering & System Design
Client–Server Multiplayer Architecture
The game uses a centralized server model where the backend acts as the single source
of truth for game state, ensuring consistency and fairness.
- Server-managed rooms and player sessions
- Authoritative turn validation on the backend
- Event-driven communication using Socket.IO
Firebase Authentication & Player Identity
Firebase Authentication was used to provide secure and frictionless login
using Google and social providers, allowing players to persist identity
across sessions and devices.
- Token-based authentication for backend validation
- Seamless account recovery and session persistence
Push Notifications & Social Invites
Firebase Cloud Messaging enables push notifications for game events such as
match invites, turn reminders, and re-engagement prompts.
- Match invite notifications via FCM
- Deep-link support for opening game rooms
- Social sharing through WhatsApp and platform-native share APIs
Network Optimization
Reduced unnecessary data transmission by sending only essential state updates
instead of full game state snapshots on every action.
Challenges & Solutions
Challenge: Secure multiplayer access and identity management
Multiplayer games require trusted player identity to prevent impersonation
and abuse.
Solution: Integrated Firebase Authentication and validated
authenticated user tokens on the backend before allowing multiplayer actions.
Challenge: Maintaining game state consistency in real-time
With multiple players performing actions concurrently, maintaining a single,
authoritative game state was critical.
Solution: Implemented server-authoritative logic where the backend
validates every move and emits synchronized events to all clients.
Impact & Results
- Improved player onboarding with frictionless social sign-in
- Increased engagement using push notifications and social invites
- Achieved secure, cheat-resistant multiplayer gameplay
- Built a scalable multiplayer foundation combining Firebase and Socket.IO