Back to Skills

sdv-mp-gamepad-audit

This skill should be used when the user asks to "check multiplayer support", "audit gamepad navigation", "verify split-screen", or before committing changes to menu code. Also use when working on per-player state, mutex locking, PerScreen usage, controller navigation, or any file in the Managers/ or Menus/ directories.

2starsUpdated 4/3/2026

Security Assessment

Safe(100/100)
Security Score100/100

About sdv-mp-gamepad-audit

The sdv-mp-gamepad-audit skill provides static code analysis to ensure robust multiplayer support and proper gamepad navigation within projects. It addresses the challenge of validating multiplayer interactions, per-player state management, and controller navigation, which are difficult to test reliably at runtime. By auditing code before manual testing, this skill helps developers catch potential issues early, reducing errors related to split-screen play, shared resources, and menu navigation. It focuses on critical areas such as state handling, context checks, mutex locking for shared objects, and unique keying for player-specific data, ensuring consistent and safe behavior across multiple players.

Key features of this skill include a structured audit checklist for per-screen state management using PerScreen<T>, context gating verification to prevent improper access to game world or player states, and mutex handling for shared furniture objects to prevent conflicts. It also enforces proper player data keying for save files and modData to avoid collisions in multiplayer environments, and provides utilities for iterating over all locations in a way that accounts for farmhands and other secondary players. These capabilities make it a comprehensive tool for code review and validation focused on multiplayer mechanics and gamepad input.

This skill is particularly useful for developers working on Stardew Valley mods or similar projects where split-screen multiplayer, per-player state, and controller navigation are important. It is designed to be run before committing changes, creating pull requests, or implementing features that impact multiple players or menus. By following its audit points, developers can ensure their code adheres to best practices for multiplayer safety and gamepad usability, ultimately improving the quality and reliability of their projects.

FAQ

When should I run the sdv-mp-gamepad-audit?

It should be run before committing changes to any files in Managers/ or Menus/, after adding new state variables, when implementing features affecting multiple players, and before creating pull requests.

Does this skill test runtime behavior?

No, it performs static code analysis to identify potential issues in multiplayer and gamepad support. Runtime testing is still necessary to validate actual behavior.

Which areas of code does this audit focus on?

It focuses on per-player mutable state, context checks, mutex locking for shared furniture, unique player data keying, location iteration for farmhands, and gamepad navigation within menus.

Can this skill handle multiple players and split-screen scenarios?

Yes, it is specifically designed to ensure proper handling of per-player state, split-screen mechanics, and shared resources in multiplayer environments.

Are there any prerequisites to using this audit?

You should have existing code changes or new features in Managers/ or Menus/ directories and understand multiplayer structures like PerScreen<T> and context checks before running the audit.

Install sdv-mp-gamepad-audit

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill