Message Based Systems

  • Messaging is not decision making structure it’s communication structure
  • Messaging systems help in CPU utilization
  • Messaging serves as a secondary system that resides below the underling decision structure of your game
  • Characteristics of Candidate AI-Systems to use Messaging Systems:

    • AI Controlled charecters are most often created to be reactive
    • AI level is very high so it’s communicating with many other game’s engines
  • Messenging System Framework:

    • Message Object
    • Message Pump
    • Client Handlers

  • Code Skeleton:

    • Message: stores individual info requirements of a message
    • MessagePump: central message router/ Acts as post office of system
    • Client Handlers: run code to accommodate any given incoming message
  • Pros of messaging systems:

    • Optimizing client-side code, where states themselves don’t care about State-Transitions
    • Decoupling class level communication advance the design
  • Cons:

    • Additional memory footprint
    • If polling action is required it’s hard and overhead to implement
  • Extension:

  • Message priority:

    • Care about starvation
  • Message arbitration:

    • See messages that could be fixed on the fly

      • Message redundancy, message collision, starving messages
  • Atomic and extended messages type:

  • Periodic message
  • Debugging messages
  • Confirmation messages
  • Immediate messages

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s