arXiv:2504.04783cs.LG2025-04

用视觉输入训练不依赖游戏数据的强化学习机器人,实现在移动设备上自动打《皇室战争》。

Playing Non-Embedded Card-Based Games with Reinforcement Learning

  • 仅用摄像头图像作为输入,不访问游戏内部状态,模拟人类玩家视角。
  • 自建生成式目标检测数据集,结合OCR和目标检测模型提取关键特征。
  • 可在手机上实时运行,击败内置AI,适合对真实交互感兴趣的开发者。

人工智能在棋类、MOBA和即时战略游戏方面已取得显著进展,但大多数复杂智能体以嵌入式方式直接获取游戏状态信息,与人类玩家依赖模糊视觉信息的方式不同,导致不公平竞争。开发非嵌入式智能体仍具挑战性,尤其在具有复杂特征和巨大状态空间的卡牌类即时战略游戏中。本文提出一种基于视觉输入的非嵌入式离线强化学习训练策略,实现《皇室战争》中的实时自主博弈。由于该游戏缺乏目标检测数据集,我们设计了一种高效的生成式目标检测数据集用于训练。通过先进的目标检测与光学字符识别模型提取特征,实现了移动端的实时图像采集、感知特征融合、决策与控制。该方法成功击败了内置AI对手。所有代码已开源至https://github.com/wty-yy/katacr。

原文摘要 · Abstract (English)

Significant progress has been made in AI for games, including board games, MOBA, and RTS games. However, complex agents are typically developed in an embedded manner, directly accessing game state information, unlike human players who rely on noisy visual data, leading to unfair competition. Developing complex non-embedded agents remains challenging, especially in card-based RTS games with complex features and large state spaces. We propose a non-embedded offline reinforcement learning training strategy using visual inputs to achieve real-time autonomous gameplay in the RTS game Clash Royale. Due to the lack of a object detection dataset for this game, we designed an efficient generative object detection dataset for training. We extract features using state-of-the-art object detection and optical character recognition models. Our method enables real-time image acquisition, perception feature fusion, decision-making, and control on mobile devices, successfully defeating built-in AI opponents. All code is open-sourced at https://github.com/wty-yy/katacr.

强化学习视觉感知游戏AI移动端

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。