How ahmed-hawass/pubg-gameloop-lag-hunter works
Lag Hunter is a Windows desktop analyzer for PUBG Mobile on GameLoop. The user starts a scan, the engine samples system and game activity, detects stutters and diagnoses likely causes; stopping or auto-stop finishes the session for later review in Reports. The interface also exposes live system, process, and Windows checks, plus settings and update controls. The sampled session code explicitly owns the sampler, detector, diagnosis, and storage responsibilities. Several backend command connections are not shown, so those links are omitted or marked unverified.
Main entry points: App.tsx App shell · bridge.ts Typed IPC bridge · session.rs Session orchestrator · sampler.rs Metric sampling
Components 23
Desktop interface
- App shell
src/App.tsx - Live monitor
src/views/MonitorView.tsx - Session reports
src/views/ReportsView.tsx - System view
src/views/SystemView.tsx - Process view
src/views/ProcessesView.tsx - Windows checks
src/views/ChecksView.tsx - Settings view
src/views/SettingsView.tsx - About view
src/views/AboutView.tsx - Typed IPC bridge
src/bridge.ts
Session analysis
- Session orchestrator
src-tauri/src/engine/session.rs - Metric sampling
src-tauri/src/engine/sampler.rs - Stutter detection
src-tauri/src/engine/detector.rs - Cause diagnosis
src-tauri/src/engine/diagnoser.rs - Engine data model
src-tauri/src/engine/types.rs
Reports and settings
- Session storage
src-tauri/src/engine/storage.rs - Settings persistence
src-tauri/src/engine/settings.rs
System and updates
- Host inspection
src-tauri/src/engine/system.rs - Update handling
src-tauri/src/engine/update.rs - Version metadata
src-tauri/src/engine/version.rs - Diagnostic logging
src-tauri/src/engine/logging.rs
Other components
- Player
- GameLoop / PUBG
- Windows host
Connections 28
- Player → App shell: uses
README.md - App shell → Live monitor: shows
src/App.tsx - App shell → Session reports: shows
src/App.tsx - App shell → System view: shows
src/App.tsx - App shell → Process view: shows
src/App.tsx - App shell → Windows checks: shows
src/App.tsx - App shell → Settings view: shows
src/App.tsx - Live monitor → Typed IPC bridge: requests data
src/views/MonitorView.tsx - Session reports → Typed IPC bridge: loads reports
src/views/ReportsView.tsx - System view → Typed IPC bridge: requests data
src/views/SystemView.tsx - Process view → Typed IPC bridge: requests data
src/views/ProcessesView.tsx - Windows checks → Typed IPC bridge: requests checks
src/views/ChecksView.tsx - Settings view → Settings persistence: configures
- About view → Typed IPC bridge: checks updates
src/views/AboutView.tsx - Typed IPC bridge → Session orchestrator: commands and state
- Session orchestrator → Metric sampling: starts sampling
src-tauri/src/engine/session.rs - Session orchestrator → Stutter detection: runs detection
src-tauri/src/engine/session.rs - Session orchestrator → Cause diagnosis: builds diagnoses
src-tauri/src/engine/session.rs - Session orchestrator → Session storage: writes sessions
src-tauri/src/engine/session.rs - Metric sampling → Engine data model: produces samples
src-tauri/src/engine/sampler.rs - Stutter detection → Engine data model: uses event types
src-tauri/src/engine/detector.rs - Cause diagnosis → Engine data model: builds diagnoses
src-tauri/src/engine/diagnoser.rs - Settings persistence → Session storage: persists settings
src-tauri/src/engine/settings.rs - Session orchestrator → Host inspection: uses host snapshots
src-tauri/src/engine/session.rs - Update handling → Version metadata: checks version
src-tauri/src/engine/update.rs - Metric sampling → GameLoop / PUBG: samples gameplay
- Metric sampling → Windows host: reads counters
src-tauri/src/engine/sampler.rs - Host inspection → Windows host: inspects host