Adaptive AI Engine for RTS Games

Discussing the theory and practice

Message Based Systems

Posted by Ogail on July 30, 2009

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

Advertisements

3 Responses to “Message Based Systems”

  1. Proud To Be Muslim said

    السلام عليكم ورحمه الله و بركاته
    الحمد لله قريتها 😀

    بس أنا حاسس أنه ده كلام عام يعني زي النظام في ال
    client / server

    العادي محستش بفرق أو محستش ألقوه الرهيبه في أستخدامها في ال
    AI

    😀 عايز أمثله تذهلني
    وياريت يا عبدو لو تبقي مطبقه في ألعاب في الحقيقه

    🙂 معلش بتقل عليك

  2. abdelrahmanogail said

    @Proud To Be Muslim
    أولا جزاك الله خيرا للإهتمام
    هوا نظام ال
    Messaging-Based Systems
    زي نظام ال
    Events in .Net
    هيا مش موجودة
    Built In
    في الكود بتاع الألعاب فعشان كده يُنصح بإستخدامها لأنها بتوفر كتير جدا في ال
    Processing

    و حبقى أوريك مثال ليها إن شاء الله 😀

  3. Proud To Be Muslim said

    جزاك الله كل خير علي المقالات و الشرح ده يا عبدو 😀
    وأنا مستني أمثلتك إن شاء الله
    😉
    وربنا يوفقكم إن شاء الله

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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 )

Google+ photo

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

Connecting to %s

 
%d bloggers like this: