Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add HermeticOrmus/LibreGameDev-Claude-Code --skill physics-patternsgit clone --depth 1 https://github.com/HermeticOrmus/LibreGameDev-Claude-CodeWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/hermeticormus/libregamedev-claude-code/physics-patterns)<a href="https://agentmods.dev/skills/hermeticormus/libregamedev-claude-code/physics-patterns"><img src="https://agentmods.dev/badge/skills/hermeticormus/libregamedev-claude-code/physics-patterns/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/hermeticormus/libregamedev-claude-code/physics-patterns"><img src="https://agentmods.dev/badge/skills/hermeticormus/libregamedev-claude-code/physics-patterns.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00054 | $0.02138 |
| Opus 5.5 | $0.00022 | $0.00855 |
| Sonnet 5.5 | $0.00011 | $0.00428 |
| Haiku 4.5 | $0.00005 | $0.00214 |
Grade A, and why
physics-patterns scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 217 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Physics Patterns
Collision Layer Configuration
# Define collision layers as constants - never magic numbers
class_name PhysicsLayers
# Layer values: collision_layer and collision_mask use bitmasks
const WORLD: int = 1 << 0 # Layer 1: Static geometry (terrain, walls)
const PLAYER: int = 1 << 1 # Layer 2: Player character
const ENEMY: int = 1 << 2 # Layer 3: Enemy characters
const PROJECTILE: int = 1 << 3 # Layer 4: Bullets, arrows, spells
const PICKUP: int = 1 << 4 # Layer 5: Collectible items
const TRIGGER: int = 1 << 5 # Layer 6: Area3D triggers (checkpoints)
const VEHICLE: int = 1 << 6 # Layer 7: Driveable objects
# Layer assignment table:
# Body Type | collision_layer | collision_mask
# Player | PLAYER | WORLD | ENEMY | PICKUP | TRIGGER
# Enemy | ENEMY | WORLD | PLAYER | PROJECTILE
# Projectile | PROJECTILE | WORLD | ENEMY (not PLAYER if friendly fire off)
# Pickup (Area3D) | PICKUP | PLAYER (only player can collect)
# Terrain (Static) | WORLD | 0 (statics don't need to detect anything)
# Usage:
# player_body.collision_layer = PhysicsLayers.PLAYER
# player_body.collision_mask = PhysicsLayers.WORLD | PhysicsLayers.ENEMY | PhysicsLayers.PICKUP
CharacterBody3D Controller (Full Featured)
class_name PlatformerCharacter extends CharacterBody3D
const SPEED: float = 6.0
const JUMP_VELOCITY: float = 6.0
const GRAVITY: float = 20.0
const FALL_GRAVITY_MULTIPLIER: float = 2.0 # Fast fall on descent
const MAX_FALL_SPEED: float = -30.0
@export var floor_snap_length: float = 0.3 # Prevents bouncing on slopes
func _ready() -> void:
# Floor snap prevents character bouncing when descending slopes
motion_mode = CharacterBody3D.MOTION_MODE_GROUNDED
floor_snap_length = 0.3
floor_stop_on_slope = true
floor_max_angle = deg_to_rad(46) # Max walkable slope
func _physics_process(delta: float) -> void:
_apply_gravity(delta)
_handle_movement()
move_and_slide()
# move_and_slide() updates velocity for you after collisions
func _apply_gravity(delta: float) -> void:
if is_on_floor():
# Keep small downward velocity for slope snapping
velocity.y = -0.1
else:
var grav := GRAVITY * delta
if velocity.y < 0:
grav *= FALL_GRAVITY_MULTIPLIER # Faster fall = better game feel
velocity.y = maxf(velocity.y - grav, MAX_FALL_SPEED)
func _handle_movement() -> void:
var input := Input.get_axis(&"move_left", &"move_right")
velocity.x = input * SPEED
func jump() -> void:
if is_on_floor():
velocity.y = JUMP_VELOCITY
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago Changed · +5 lines · +54 tokens per session 1b7239d85f45
- 3mo ago First seen · 212 lines · 0 tokens per session scan A b1cefc67114a
physics-patterns is a skill published in the GitHub repository HermeticOrmus/LibreGameDev-Claude-Code (5 stars, last pushed 2mo ago), licensed MIT. It adds 54 tokens to every session and 2,138 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
physics-patterns compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| physics-patternsHermeticOrmus/LibreGameDev-Claude-Code | Skill | 5 | 2mo ago | MIT | A | 54 | Claude Code |
| unity-cliAlex-Rachel/TEngine | Skill | 2.4k | 12d ago | MIT | A | 68 | Codex |
| luban-devAlex-Rachel/TEngine | Skill | 2.4k | 12d ago | MIT | A | 63 | Codex |
| html-to-uguiAlex-Rachel/TEngine | Skill | 2.4k | 12d ago | MIT | A | 75 | Codex |
| tengine-devAlex-Rachel/TEngine | Skill | 2.4k | 12d ago | MIT | A | 71 | Codex |
| godot-masterbgrenat/godot-game-dev-studio | Skill | 31 | 21d ago | LGPL-3.0 | A | 170 | Claude Code, Codex |
| godot-2d-animationbgrenat/godot-game-dev-studio | Skill | 31 | 21d ago | LGPL-3.0 | A | 109 | Claude Code, Codex |