Docs  /  Gaming RL

Gaming RL

Gaming RL is the generic first-person gaming reinforcement-learning subsystem. It is separate from Minecraft DQN, but it follows the same structure: observe state, choose actions, record transitions, train/evaluate policies, and only actuate when the selected mode permits it.

Use this only in local/private environments where automation is allowed.

RL hub: ReinforcementLearning.md · MathNN: rl net enable gaming_fps / rl net mode gaming_fps actor-critic — see MathNN.md.

For the full FPS state/action reference, see docs/GamingRLFPS.md. For Source, Quake, Garry's Mod, and Civilization bridge setup, see docs/GameModBridges.md.

Modes

off
assist
bot
train
eval
imitate

Start in dry-run:

gaming rl init
gaming rl adapter set generic_fps
gaming rl dry-run on
gaming rl input hold 120
gaming rl input mouse 32
gaming rl status

Game mod bridge smoke test:

gaming rl init
gaming rl dry-run on
gaming mod bridge configure source_mod 0.0.0.0 8767 YOUR_TOKEN true
gaming mod bridge configure quake_mod 0.0.0.0 8768 YOUR_TOKEN true
gaming mod bridge configure garrys_mod 0.0.0.0 8771 YOUR_TOKEN true
gaming mod bridge configure civilization_mod 0.0.0.0 8772 YOUR_TOKEN true
gaming mod bridge status
gaming mod bridge tail source_mod 10

Algorithms

heuristic
random
qtable
linear_q
sarsa
reinforce
mlp
dqn
remote
auto

Commands:

gaming rl algorithm heuristic
gaming rl algorithm qtable
gaming rl algorithm linear_q
gaming rl algorithm dqn
gaming rl algorithm auto
gaming rl epsilon <value>
gaming rl blend <value>

Core Commands

gaming rl status
gaming rl features
gaming rl systems
gaming rl skills
gaming rl skill use <action_id>
gaming rl explain
gaming rl why

gaming rl on
gaming rl assist
gaming rl bot
gaming rl train
gaming rl eval [episodes]
gaming rl off

skill use forces one action and is useful for checking input routing.

Adapter And Perception

gaming rl adapter status
gaming rl adapter set <name>
gaming rl perception <request>
gaming rl bridge spec
gaming mod bridge status
gaming mod bridge start [source_mod|quake_mod|garrys_mod|civilization_mod|all]
gaming mod bridge tail [source_mod|quake_mod|garrys_mod|civilization_mod|all] [count]

Adapters are responsible for filling FPSPerception: target location, HUD values, menu/death state, hit markers, audio threat, minimap threat, objective distance, and movement context.

source_mod, quake_mod, and garrys_mod provide server-side health/damage/death telemetry. Use them together with client-side screen/HUD/audio perception when training aim or navigation policies.

civilization_mod feeds turn-state observations into GamingStrategyRL and returns high-level strategy recommendations such as prioritize_science, raise_military, scout, and settle_city.

Input Safety

gaming rl dry-run on
gaming rl dry-run off
gaming rl input hold <milliseconds>
gaming rl input mouse <max_pixels_per_tick>

Use dry-run on until observations and action selection are correct. input hold controls timed key holds for smoother movement. input mouse limits mouse movement per tick.

Curriculum

gaming rl curriculum status
gaming rl curriculum start [phase]
gaming rl curriculum next
gaming rl curriculum phase <name>

Recommended phase order:

input_smoke
aim_static
aim_tracking
movement_basic
cover_peek
objective_push
offline_replay
eval_gate

Replay And Behavior Cloning

gaming rl replay summary [path]
gaming rl replay tail
gaming rl replay train [path]
gaming rl bc train [epochs]
gaming rl bc status

Replay training imports transition logs. Behavior cloning trains from imitation examples managed by GamingSimulation.

Rewards And Checkpoints

gaming rl reward good [note]
gaming rl reward bad [note]
gaming rl reward <number> [note]

gaming rl checkpoint tag <tag>
gaming rl checkpoint list
gaming rl checkpoint rollback <tag>
gaming rl save
gaming rl load
gaming rl save mysql
gaming rl load mysql
gaming rl checkpoint mysql on
gaming rl checkpoint mysql off
gaming rl checkpoint mysql profile <profile>

Runtime Files

Default log directory:

D:/gaming_rl_logs

Important files:

gaming_rl_checkpoint.txt
transitions.csv
fps_dashboard.json
fps_heatmap.csv
fps_bridge_protocol.json
fps_perception_requests.jsonl
fps_episode_events.jsonl
checkpoint_<tag>.txt

Lua Globals

Agents can call:

gaming_rl_status()
gaming_rl_set_mode(mode)
gaming_rl_get_mode()
gaming_rl_set_algorithm(algorithm)
gaming_rl_get_algorithm()
gaming_rl_start_episode()
gaming_rl_end_episode()
gaming_rl_save()
gaming_rl_load()
gaming_rl_save_mysql()
gaming_rl_load_mysql()
gaming_rl_init()
gaming_rl_shutdown()

Safe Operating Pattern

  1. gaming rl dry-run on
  2. Verify adapter status and perception requests.
  3. Force each action with gaming rl skill use <id>.
  4. Train from replay before live actuation.
  5. Use eval and checkpoint tags.
  6. Roll back if reward, policy explanation, or behavior degrades.
Generated from the project markdown docs on 2026-07-24. This is a static, self-contained site.