{
  "id": "unity/input-system-action-map-not-found",
  "signature": "InvalidOperationException: InputActionMap 'Gameplay' not found in InputActionAsset 'Controls'.",
  "signature_zh": "无效操作异常：在输入操作资源'Controls'中未找到输入操作映射'Gameplay'。",
  "regex": "InputActionMap '[^']+' not found in InputActionAsset '[^']+'",
  "domain": "unity",
  "category": "config_error",
  "subcategory": null,
  "root_cause": "Code references an InputActionMap name that does not exist in the assigned InputActionAsset asset.",
  "root_cause_type": "generic",
  "root_cause_zh": "代码引用了一个在分配的输入操作资源中不存在的输入操作映射名称。",
  "versions": [
    {
      "version": "1.4",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "1.5",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "1.6",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "1.7",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "Random names never match the asset; the name must exactly match the one in the .inputactions file.",
      "fail_rate": 0.9,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "This loses all existing bindings and requires reconfiguring controls, which is overkill for a missing map name.",
      "fail_rate": 0.4,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "ListEnabledActions returns actions, not maps; it does not help locate the correct map name.",
      "fail_rate": 0.7,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Open the InputActionAsset (e.g., 'Controls.inputactions') in the editor, verify the map name is 'Gameplay', and correct the code: InputActionMap gameplayMap = inputAsset.FindActionMap(\"Gameplay\"); If the map is named differently, update the string.",
      "success_rate": 0.98,
      "how": "Open the InputActionAsset (e.g., 'Controls.inputactions') in the editor, verify the map name is 'Gameplay', and correct the code: InputActionMap gameplayMap = inputAsset.FindActionMap(\"Gameplay\"); If the map is named differently, update the string.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Use FindActionMap with a fallback: var map = inputAsset.FindActionMap(\"Gameplay\") ?? inputAsset.FindActionMap(\"Default\"); This prevents crashes but may not bind the correct actions.",
      "success_rate": 0.7,
      "how": "Use FindActionMap with a fallback: var map = inputAsset.FindActionMap(\"Gameplay\") ?? inputAsset.FindActionMap(\"Default\"); This prevents crashes but may not bind the correct actions.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Regenerate the InputActionAsset from a template that includes the missing map: right-click > Create > Input Actions, then copy the map structure from the old asset.",
      "success_rate": 0.85,
      "how": "Regenerate the InputActionAsset from a template that includes the missing map: right-click > Create > Input Actions, then copy the map structure from the old asset.",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Open the InputActionAsset (e.g., 'Controls.inputactions') in the editor, verify the map name is 'Gameplay', and correct the code: InputActionMap gameplayMap = inputAsset.FindActionMap(\"Gameplay\"); If the map is named differently, update the string.",
    "Use FindActionMap with a fallback: var map = inputAsset.FindActionMap(\"Gameplay\") ?? inputAsset.FindActionMap(\"Default\"); This prevents crashes but may not bind the correct actions.",
    "Regenerate the InputActionAsset from a template that includes the missing map: right-click > Create > Input Actions, then copy the map structure from the old asset."
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://docs.unity3d.com/Packages/com.unity.inputsystem@1.7/manual/ActionAssets.html",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.89,
  "fix_success_rate": 0.95,
  "resolvable": "true",
  "first_seen": "2024-03-22",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}