Modern and advanced Counter-Strike 2 aim training application. Improve your aim with real CS2 sensitivity settings, track your performance, and break your records!
- ๐ฏ Circle Target: Hit randomly appearing circles (60 seconds)
- โก Reaction Time: Test your reflexes (2-6 seconds interval)
- Real CS2 Sensitivity: Use your in-game sensitivity settings
- DPI Calculation: Effective DPI calculation
- Mouse Movement: Real CS2 mouse movement system
- Detailed Charts: Performance graphs with Recharts
- Score Tracking: Cloud-based score storage with Firestore
- Progress Analysis: View improvement over time
- Best Scores: Track personal records
- Firebase Auth: Secure login/register system
- User Profile: Personal information and logout
- Protected Routes: Secure page access
- Node.js 20.16.0+
- npm 10.8.2+
# Clone the project
git clone [repo-url]
cd cs2-aim-training
# Install dependencies
npm install
# Setup environment variables
cp .env.example .env
# Edit .env file with Firebase config details
# Start development server
npm run dev- Create new project on Firebase Console
- Enable Authentication (Email/Password)
- Enable Firestore Database
- Add web app and get config details
- Fill
.envfile with Firebase config:
VITE_FIREBASE_API_KEY=your_api_key
VITE_FIREBASE_AUTH_DOMAIN=your_auth_domain
VITE_FIREBASE_PROJECT_ID=your_project_id
VITE_FIREBASE_STORAGE_BUCKET=your_storage_bucket
VITE_FIREBASE_MESSAGING_SENDER_ID=your_sender_id
VITE_FIREBASE_APP_ID=your_app_id- Open the app:
http://localhost:5173 - Create account or login
- Set your CS2 sensitivity settings in main menu
- Adjust DPI value
- Circle Target: Hit random circles in fullscreen mode
- Reaction Time: Click immediately when you see blue screen
- Statistics: Track your performance with graphs
- Enter your CS2
sensitivityvalue - Specify your mouse DPI
- Effective DPI calculated automatically
- Settings saved automatically
- React 18: Modern UI framework
- Vite: Fast build tool
- Tailwind CSS: Utility-first CSS framework
- React Router: Client-side routing
- Recharts: Data visualization
- Firebase Auth: User authentication
- Firestore: NoSQL database
- Real-time: Live data synchronization
- Pointer Lock API: Fullscreen mouse control
- CS2 Sensitivity: Real game sensitivity
- Performance Optimized: GPU accelerated movements
- Score: Number of targets hit
- Accuracy: Hit percentage (hit/total shots)
- Duration: 60 seconds
- Storage: Saved in Firestore
- Time: In milliseconds
- Categories:
- ๐ Super Fast (< 200ms)
- โก Very Good (200-300ms)
- ๐ Good (300-400ms)
- ๐ Slow (> 400ms)
# Development server
npm run dev
# Production build
npm run build
# Preview production build
npm run preview
# Linting
npm run lintsrc/
โโโ components/ # React components
โ โโโ Auth.jsx # Login/Register
โ โโโ MainMenu.jsx # Main menu
โ โโโ CircleTargetGame.jsx
โ โโโ ReactionTimeGame.jsx
โ โโโ Statistics.jsx # Statistics page
โโโ hooks/ # Custom hooks
โ โโโ useAuth.js # Authentication hook
โโโ services/ # API services
โ โโโ scoreService.js # Score management
โโโ firebase/ # Firebase config
โโโ utils/ # Helper functions
โโโ assets/ # Static files
// Effective DPI = CS2 Sensitivity ร Mouse DPI
const effectiveDPI = sensitivity * dpi;
// CS2 YAW value: 0.022 (constant)
const yaw = 0.022;
// Mouse movement calculation
const rotationX = movementX * sensitivity * yaw;
const rotationY = movementY * sensitivity * yaw;- Firestore composite index requirement (solved with simple queries)
- Pointer Lock API may not be fully supported in some browsers
- Limited support on mobile devices
- Fork the project
- Create feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add some amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Create Pull Request
This project is licensed under the MIT License.
- More game modes
- Multiplayer support
- Leaderboard system
- Crosshair customization
- Sound effects
- Mobile responsive design
- Steam integration
๐ฎ Good luck! Improve your aim, break your records! ๐ฏ