Using Game Development Tools to Make your Bot Smarter

In the September session of Postbots, Drekken hosts Ketrock and Hammer (@craig ), delving into Hammer’s AI bot, T-Bone. T-Bone is a Terran bot utilizing a unique decision-making process called utility AI, commonly used in AAA games for AI agents.

The session highlights the potential of utility AI to enhance bot decision-making, offering a more flexible and scalable alternative to traditional methods.

Highlights:

  1. Utility AI Explanation:

    • Hammer explains that T-Bone uses utility AI instead of traditional machine learning. Utility AI evaluates various factors to make decisions without relying on predefined if-else statements.
    • This allows T-Bone to handle edge cases better and potentially exhibit emergent behaviors by evaluating multiple observations.
  2. Application in Bot Decision Making:

    • Hammer uses utility AI for unit decisions, such as a Reaper deciding between attacking, throwing a grenade, or moving.
    • The AI makes these decisions by calculating scores for different actions based on observations like distance to target, weapon cooldown, target health, and surrounding threats.
  3. Implementation Details:

    • T-Bone is programmed in Python and utilizes the Sharpie framework for basic bot functionality.
    • Hammer has integrated utility AI into Python, handling complex decision-making by translating it from concepts used in other languages and frameworks.
  4. Demo and Technical Breakdown:

    • Hammer demonstrates the bot’s decision-making process in a game scenario, showing how the Reaper evaluates targets and actions in real time.
    • The demo includes a detailed view of the considerations and response curves used to calculate action scores.
  5. Challenges and Future Plans:

    • Hammer discusses the computational challenges of implementing utility AI in Python, especially for larger groups of units.
    • Plans to possibly convert the decision-making system to C for better performance and to extend utility AI to more units and higher-level strategies.
  6. Potential for Broader Adoption:

    • Hammer suggests that utility AI could significantly improve bot performance and decision-making.
    • The idea of developing a library for utility AI in Python is discussed, which could benefit the bot development community by providing a standardized approach for complex decision-making.

For those interested in trying out utility AI or learning more, Hammer suggests watching the 2015 GDC presentation on utility AI and exploring available resources for implementation.