Skip to content
ManApart edited this page Feb 12, 2023 · 10 revisions

AI

The AI system is designed to meet the following goals

  • Be as powerful as possible
    • Able to express any desired behavior / directed for a specific quest or situation
    • Doesn't do anything unique from player actions. All posted events are shared with player events. (Reuse events for better simulation cohesion)
    • Modular and emergent. "Decisions" should be easy to be reused and combined in other ways. Should be addative

General Thoughts

Rat AI

  • only attack with low aim
  • Approach dagger range if not already in dagger range

Combat training dummy

  • Player controlled ai
  • Used to test fights

Player Controlled AI

  • All commands have an execute(source, keyword, args). Default delegates to execute(keyword, args). Supported commands create their event using source instead of player.
  • Command parser is passed the Target that is issuing the command. 99% of the time it’s the player, but could be a player controlled AI.

Ai has two properties, Ai state and ai state time

Make AI run not only during battle, but give it an on-tick listener where it can integrate game state and decide to do something. (And start with it allowing player controlled ai to make a choice) Only evaluate AI for current location

Maybe all command parsing come from AI and if not in battle / command is not an on-tick command, just cycle next ai etc.

Desires only dictate what will be done. NOT how it will be done.

Agendas don't include any choices, merely the implementation details of how to accomplish a given goal. If the coal cannot be completed, returning a null event will trigger the ai to re-evaluate its goals

Approaches

Goals for AI

Easy to expand. Modular and orthogonal

Dynamic to world changes

Can be influenced by player actions and charisma

Feeds into and affected by conversation where possible

Next Steps

Make conversations not nested but just tags for the result line

Facts: add properties

  • Use for things like hometown / owned by?

Rat retreats

ai interaction with quests

upgrade gradle / kotlin

Clone this wiki locally