{
  "schemaVersion": 1,
  "atomId": "pin_pull.aigameplay",
  "bundleType": "aigameplay",
  "category": "gameplay",
  "mode": "fixed",
  "label": {
    "zh": "拔针解谜玩法",
    "en": "Pin Pull puzzle gameplay"
  },
  "tags": [
    "gameplay",
    "pin",
    "pull",
    "liquid",
    "physics",
    "puzzle",
    "casual"
  ],
  "bindingRoles": [
    "gameplayRule"
  ],
  "imports": [
    {
      "slot": "engine",
      "pinAtomId": "phaser.aicomponent",
      "edgeKind": "requires",
      "bindAs": "engine"
    },
    {
      "slot": "bgMusic",
      "description": "背景循环音乐",
      "bindAs": "bgm",
      "required": false,
      "edgeKind": "compatibleWith",
      "matchBindingRoles": [
        "bgMusic"
      ],
      "allowedBundleTypes": [
        "aiaudio"
      ],
      "constraints": {
        "loop": true
      }
    },
    {
      "slot": "background",
      "description": "游戏背景图",
      "bindAs": "bg",
      "required": false,
      "edgeKind": "compatibleWith",
      "matchBindingRoles": [
        "backgroundTexture"
      ],
      "allowedBundleTypes": [
        "aiimage"
      ]
    },
    {
      "slot": "levelDataPack",
      "description": "关卡数据包",
      "bindAs": "levels",
      "required": false,
      "edgeKind": "compatibleWith",
      "matchBindingRoles": [
        "levelDataPack"
      ],
      "allowedBundleTypes": [
        "aiconfig"
      ]
    },
    {
      "slot": "tutorial",
      "description": "新手引导浮层",
      "bindAs": "tutorial",
      "required": false,
      "edgeKind": "compatibleWith",
      "matchBindingRoles": [
        "tutorialOverlay"
      ],
      "allowedBundleTypes": [
        "aicomponent"
      ]
    },
    {
      "slot": "winPanel",
      "description": "通关反馈面板视觉",
      "bindAs": "winPanel",
      "required": false,
      "edgeKind": "compatibleWith",
      "matchBindingRoles": [
        "successFeedbackPanel"
      ],
      "allowedBundleTypes": [
        "aiimage"
      ]
    },
    {
      "slot": "losePanel",
      "description": "失败反馈面板视觉",
      "bindAs": "losePanel",
      "required": false,
      "edgeKind": "compatibleWith",
      "matchBindingRoles": [
        "failFeedbackPanel"
      ],
      "allowedBundleTypes": [
        "aiimage"
      ]
    },
    {
      "slot": "endScreen",
      "description": "可玩广告结算屏（含 CTA 按钮）",
      "bindAs": "endScreen",
      "required": false,
      "edgeKind": "compatibleWith",
      "matchBindingRoles": [
        "playableEndScreenLayout"
      ],
      "allowedBundleTypes": [
        "aicomponent"
      ]
    }
  ],
  "generation": {
    "kind": "pgs",
    "pgsVersion": "1.0",
    "gameplayType": "pin_pull",
    "rules": {
      "liquidFlowEnabled": true,
      "multiPinSequencing": true,
      "dangerZoneEnabled": true,
      "gravitationalFlow": true
    }
  },
  "result": {
    "outputFile": "reducer.ts",
    "format": "typescript",
    "constraints": {
      "testCasesMustPass": true
    }
  },
  "binding": {
    "role": "gameplayRule",
    "target": "game/gameplay/pin_pull/reducer.ts",
    "type": "gameplay-module-reference",
    "constraints": {
      "interface": [
        "init(config)",
        "dispatch(action)",
        "getState()",
        "canPullPin(state, pinId)",
        "pullPin(state, pinId)",
        "simulateLiquidFlow(state)",
        "checkWinLose(state)"
      ]
    }
  },
  "files": {
    "skill": "SKILL.md",
    "pgsSchema": "ref/pgs-schema.json",
    "reducerTemplate": "ref/reducer.template.ts"
  }
}
