Backpack Battles MCP
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| bpb_get_stateA | 获取当前完整状态:state(title/shop/combat)、职业、回合、剩余重试次数、金币、当前 run 胜场 wins、累计胜场 total_wins、生存模式状态 survival、商店物品/技能及价格、保留项、刷新费、背包 9x7 摆盘(bags/items/grid)、储物箱、战斗结算是否可跳过。战斗期间只返回摘要(inventory_available=false),不会触碰背包/商店;结算后回到 shop 再读取完整状态。返回的 id 字段用于后续 buy/place/rotate/store/reserve/socket 操作;item.fusion_locked / item.locked 是融合锁定状态;item.is_gem 与 item.sockets 用于宝石镶嵌。 |
| bpb_get_phaseA | 轻量状态:state/round/tries/gold/wins/total_wins/survival/can_skip_result/last_result。战斗期间可安全调用,不会触碰背包;用于等待结算或判断是否进入下一阶段。 |
| bpb_get_backpackA | 读取当前完整背包布局:所有已部署背包(位置/cells/shape/rotation)、所有已放置物品(位置/cells/shape/rotation/bag_id/floating/fusion_locked/is_gem/sockets)、grid、储物箱,以及 bags/items/floating/outside/fusion_locked/socketed_gems 计数。只读,不触发 normalize 或存档写入。 |
| bpb_get_star_slotsA | 读取星位/受影响格与宝石插槽。返回每件已放置物品的 affected_cells(按方向 0/2/4/7)、current_affected_items(当前命中物品)、extension_cells 和 sockets(index/位置/occupied/gem_id/gem_name)。可选 item_id 只查一件。 |
| bpb_get_staminaA | 读取耐力信息:玩家 stamina/max_stamina/stamina_regen(游戏未暴露时对应字段为 null 且 available=false)、每件物品的 stamina_cost/stamina_factor/types/伤害/冷却,以及已部署物品的总耐力消耗。 |
| bpb_get_recipesA | 读取合成配方:每件背包/储物箱物品的 recipes(base/result/ingredients/all_ingredients/catalyst)、as_ingredient(作为材料的配方)、gated_items(牌堆可生成卡牌)。全量只查背包/储物箱;商店物品用 item_id 单查(全量遍历个别 shop 配方不稳定)。 |
| bpb_buy_itemA | 购买商店物品并放入储物箱。若 state.shop.choose_one=true(第 3/10 回合的技能商店),则选择一个技能并放入储物箱(返回 skill_id);技能是 1×1 可摆放物品,再用 bpb_place_item 摆进背包。购买后会补发 dropped 信号,触发 Unidentified Skill 等 onDropped 购买效果。用 slot(1-5)或 item_id 指定。 |
| bpb_refresh_shopA | 刷新商店(消耗金币,费用见 state.shop.reroll_cost)。 |
| bpb_open_backpack_editB | 进入背包层编辑模式(inventoryEditMode=bag),用于移动/旋转背包本体。 |
| bpb_open_item_editB | 进入物品层编辑模式(inventoryEditMode=item);可选 item_id 聚焦某件物品。 |
| bpb_reserve_itemB | 保留/取消保留商店物品(reserve)。保留后该物品会留在商店,跨刷新/下回合仍可购买;reserved=false 表示取消保留。用 slot(1-5)或 item_id 指定。 |
| bpb_store_itemA | 把背包里的物品放回储物箱(腾出格子)。不能用于背包本体;用于给技能/新物品腾位置。 |
| bpb_sell_itemA | 出售背包里的物品,立即获得金币(价格见 state.backpack.items[].sell_price)。储物箱里的物品需先 bpb_place_item 放回背包再出售。 |
| bpb_set_fusion_lockA | 锁定或解除物品的自动融合。locked=true 锁定(阻止自动合成),locked=false 解除;背包和储物箱物品可用,背包本体不可用。state 中 item.fusion_locked 反映结果。 |
| bpb_socket_gemA | 把宝石类物品镶到宿主物品的空镶嵌位。host_id 的 state.sockets 提供 socket_index、occupied、gem_id;宝石可以是背包或储物箱中的散装宝石。镶嵌是原子的,不走 drop/hotswap。 |
| bpb_unsocket_gemA | 从宿主物品的镶嵌位取下宝石。优先放回背包空格;没有空格时放储物箱。 |
| bpb_edit_itemsA | 进入“只编辑物品”模式:背包固定不动,物品可以放到任意格子(包括包外)。用于购买后先把物品摆到理想位置。 |
| bpb_edit_bagsA | 进入“只编辑背包”模式:物品固定不动,背包可以移动/旋转,移动背包不会牵连物品。用于把背包移动到覆盖物品的位置。 |
| bpb_edit_allB | 进入“编辑全部”模式并规范化落格;不会把跨包/包外物品移入储物箱。物品可以同时被多个背包覆盖,游戏没有单一背包限制。 |
| bpb_set_edit_modeB | 切换编辑模式:all(全部)/bags(只背包)/items(只物品);兼容 default/bag/item 别名。 |
| bpb_set_classA | 标题界面选择职业(0=Ranger,1=Reaper,2=Berserker,3=Pyromancer,4=Mage,5=Adventurer,6=Engineer);可同时指定 loadout(0-2),随后用 bpb_start_run 开局。 |
| bpb_set_loadoutA | 标题界面选择初始 loadout(0-2);具体物品见 state.title.classes[].loadouts。 |
| bpb_place_itemB | 原生落格:pickup(当前物品位置) → 设目标包围盒中心 → Item.drop(),成功返回的 cells 精确等于目标格,并触发游戏正常的落格/放置回调。物品/全部模式下允许放到包外(outside_bag=true);物品可以同时覆盖多个背包,不要求属于单一背包;位置/朝向由游戏 drop 校验。 |
| bpb_place_bagA | 移动背包到指定左上角格子 (x,y)。只允许移动空背包;非空背包返回 bag_not_empty,需先用 bpb_place_item/bpb_store_item 把内容移出,再移动空包。物品模式返回 bags_fixed_in_item_mode。 |
| bpb_rotate_itemB | 游戏内原子旋转(已启用):目标格全在包内且无重叠时,直接 removeItem → orientItem → addItemByTopLeft,不经过 drop/tryAddItem/hotswap。支持矩形和 L 形;目标不合法返回 cannot_rotate_in_place。BPB_ROTATE=0 可关闭。 |
| bpb_rotate_bagA | 游戏内原子旋转空背包(已启用):目标格全在包内且无重叠时,removeItem → orientItem → addItemByTopLeft;非空背包返回 bag_not_empty。BPB_ROTATE=0 可关闭。 |
| bpb_start_battleA | 开始战斗;开战前只规范化物品位置/placedByPlayer,不会把跨包物品移入储物箱。随后用 bpb_wait_for_result 等待结算。 |
| bpb_skip_resultA | 跳过战斗结算界面回到商店(仅在 state.can_skip_result=true 时调用)。十胜时即使 state.survival.prompt_visible 仍为 false,也会返回 survival_choice_required;必须先 bpb_choose_survival / bpb_enter_survival / bpb_stop_here 做出选择。 |
| bpb_enter_survivalA | 十胜时选择“进入生存模式”。state.survival.can_start=true 即可调用;若原生提示仍在 1 秒延迟中,会主动打开提示后再进入。不会先结算奖杯。 |
| bpb_stop_hereA | 十胜提示时选择“到此为止”。仅在 state.survival.prompt_visible=true 时可用;结束本轮并保留胜场。 |
| bpb_choose_survivalA | 统一处理 10 胜提示:choice=survival 等价 bpb_enter_survival,choice=stop 等价 bpb_stop_here。 |
| bpb_wait_for_resultA | 等待战斗结算界面出现;auto_skip=true 时自动跳过并返回下一回合商店状态。十胜时不会先跳过结算(包括原生提示的 1 秒延迟窗口);会返回 survival_choice_required,等待选择生存模式或到此为止。 |
| bpb_start_runA | 开始新的一局。默认优先恢复挂起的 run;force_new=true 会删除挂起的 run 并强制全新开局(适用于旧存档损坏、continue 崩溃的情况)。mode=unranked/ranked。新局第一回合生命上限强制重置为 25(不继承上一局),返回 hp。可选 class_id/loadout:开局前先选择职业与初始 loadout。 |
| bpb_continueB | 从标题界面继续挂起的 run(等价于点击“继续”)。 |
| bpb_healthA | 检查游戏内网桥是否在线,返回 ping 与当前状态摘要。 |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 35 tools
Several tools overlap heavily, especially the edit-mode family (bpb_open_backpack_edit, bpb_open_item_edit, bpb_edit_items, bpb_edit_bags, bpb_edit_all, bpb_set_edit_mode) and the survival-choice family (bpb_enter_survival, bpb_stop_here, bpb_choose_survival). The descriptions explain differences, but an agent can easily misselect among these redundant entry points.
All tools use the bpb_ prefix with snake_case and generally follow a verb_noun pattern (e.g. bpb_buy_item, bpb_place_item, bpb_get_state). Minor bare verbs like bpb_health and bpb_continue are still clearly readable and consistent with the overall convention.
35 tools is heavy for any server, and the set includes multiple redundant edit-mode and survival-choice wrappers that inflate the count. While the game domain is complex, the surface could be consolidated to a much tighter set without losing capability.
The surface covers the core game lifecycle well: title/class/loadout, shop buying/reserving/refreshing, inventory placement/rotation/storage/selling, gem sockets, battle start/result, and survival branching. There are minor gaps around consolidated inventory editing and item inspection, but agents can work around them using the existing state and item tools.