PolyDiff — A Multiplayer Spot the Difference Game
Real-time multiplayer • Cross-platform gaming • Advanced game modes • Game creation tools
PolyDiff is an interactive multiplayer spot-the-difference game developed for the LOG3900 course. The project consists of three main components:
- A desktop client (Electron/Angular) with game creation and administration capabilities
- A mobile client (Android) optimized for touch-based gameplay
- A NestJS backend server handling game logic, user management, and real-time communications
The game features multiple game modes including Classic (up to 4 players), Team Mode, and Time Limited challenges. Players can create custom game levels, join ongoing games as observers, and interact through an integrated chat system.
The project consists of three main components:
- Built with Angular and Electron
- Provides a rich drawing interface
- Supports real-time collaboration
- Integrated chat system
- Cross-platform compatibility
- Native Android application
- Kotlin-based implementation
- Touch-optimized drawing interface
- Real-time synchronization
- Mobile-friendly chat system
- Built with NestJS framework
- WebSocket support for real-time features
- RESTful API endpoints
- User authentication and management
- Data persistence and session handling
- Shared TypeScript interfaces
- Common constants and enums
- Cross-component type definitions
- Shared utility functions
flowchart TB
subgraph Clients["Game Clients"]
Desktop["Desktop Client\nGame Creation & Playing"]
Mobile["Mobile Client\nOptimized for Play"]
end
subgraph GameServer["Game Server"]
GameLogic["Game Logic"]
MatchMaking["Matchmaking"]
Chat["Chat System"]
ReplaySystem["Replay System"]
end
subgraph DataLayer["Data Management"]
UserProfiles["User Profiles"]
GameData["Game/Level Data"]
MatchHistory["Match History"]
end
Desktop --> GameLogic
Desktop --> MatchMaking
Mobile --> GameLogic
Mobile --> MatchMaking
GameLogic --> ReplaySystem
GameLogic --> Chat
MatchMaking --> GameData
Chat --> UserProfiles
Desktop -.-> |"Game Creation"| GameData
ReplaySystem --> MatchHistory
- Desktop Client: Full-featured client with game creation capabilities
- Mobile Client: Optimized for touch-based gameplay
- Real-time game state management
- Match creation and player grouping
- Chat system with multiple channels
- Replay recording and playback
- User profiles and authentication
- Game level storage
- Match history and statistics
- Node.js 18+ (for desktop client and server)
- Android Studio (for mobile client)
- Git
cd serveur
npm install
npm run start:devThe server will be available at http://localhost:3000
cd client-lourd
npm install
npm startThe desktop application will launch automatically
- Open
client-leger/in Android Studio - Sync Gradle files
- Build and run on an emulator or physical device
- 2-4 player competitive gameplay
- Find differences in image pairs
- Score tracking and time limits
- Winner determined by most differences found
- 2-3 teams of 2 players each
- Collaborative difference spotting
- Shared team penalties
- Team-based scoring system
- Fast-paced single difference challenges
- Time bonuses for correct finds
- Rotating image pairs
- Progressive difficulty
- Custom game level creation
- Drawing tools (Rectangle, Ellipse, Paint bucket)
- Random difference generator
- Game management interface
- Real-time multiplayer support
- Integrated chat system with multiple channels
- Observer mode with player interactions
- Team formation and management
- Visual and sound effects for actions
- Cheat mode with difference highlighting
- Video replay system with timeline
- Multi-language support
- Customizable themes
- Desktop client (Windows 10+)
- Android client (Android 9+)
- Consistent gameplay experience
cd client-lourd
npm install
npm run start:devThe desktop client includes:
- Game creation interface with drawing tools
- Administration panel for game management
- Full game hosting capabilities
- Comprehensive replay system
cd client-leger
./gradlew buildThe Android client features:
- Touch-optimized gameplay
- Camera integration for avatar capture
- Mobile-friendly chat interface
- Notification system
cd serveur
npm install
npm run start:devServer capabilities:
- Game state management
- Real-time game synchronization
- User authentication & profiles
- Match history tracking
- WebSocket communication
When updating shared interfaces or constants:
- Make changes in
common/ - Update version in package.json
- Update all dependent projects
Each component includes its own test suite:
- Server:
cd serveur && npm test - Desktop:
cd client-lourd && npm test - Mobile: Use Android Studio's test runner
Generate coverage reports:
npm run coverageCoverage reports will be available in the /coverage directory of each component.
- ESLint configuration is provided for each component
- Run linting checks with
npm run lint - TypeScript strict mode enabled
- Consistent code style across all components
- Use TypeScript types strictly (avoid
any) - Prefer arrow functions over
functionkeyword - Keep functions single-responsibility
- Use constants for magic numbers/strings
- Follow component-specific architecture patterns
- Feature branches:
feature/feature-name - Bug fixes:
hotfix/bug-name - Use kebab-case for branch names
- Write clear, concise commit messages
- Use present tense ("Add feature" not "Added feature")
- Reference issues where appropriate
- Keep changes focused and atomic
- Request reviews from team members
- Ensure CI passes before merging
- Squash commits when merging to master
See DEPLOYMENT.md for detailed deployment instructions for each component.
All executables must be generated in Release mode for evaluation:
- Desktop Client:
cd client-lourd
npm run build:prodGenerated in client-lourd/build/
- Mobile Client:
cd client-leger
./gradlew assembleReleaseGenerated APK in client-leger/app/build/outputs/apk/release/
- Server:
cd serveur
npm run buildGenerated in serveur/dist/
LOG3900-104/
├── client-lourd/ # Desktop client (Windows)
│ ├── src/ # Source code
│ └── build/ # Generated executables
├── client-leger/ # Mobile client (Android)
│ ├── app/ # Application code
│ └── build/ # Generated APK
├── serveur/ # Game server
│ ├── src/ # Server implementation
│ └── dist/ # Compiled server
└── common/ # Shared definitions
- Émile Watier
- [Other Team Members]
This project was developed for the LOG3900 course at Polytechnique Montréal. It demonstrates:
- Real-time multiplayer game development
- Cross-platform client development
- Backend server implementation
- User interface design
- Network programming
Built with ❤️ by the LOG3900-104 Team