/* ==================== msg_port.h ==================== version 0.0.0 ==================== Message Ports are modules fitted to pods that allow them to communicate with each other, both friend and foe. Message ports allow for a variety of communications and messages to be sent and received. Think of message ports as "infrared beacons" for inter-pod communication. The reason MPs are a seperate class is to clarify the Pod class code and to further black-box the communication mechanics between pods, since communication is not actually part of a pod itself, but more of an interaction. CHANGELOG: ---------------------- 0.0.1 - in progress TO-DO & EXPANSION LIST ---------------------- - make friends with Pod class? =============================================================== */ #ifndef MSG_PORT_H #define MSG_PORT_H // defined elsewhere class Pod; class Map; #include "pod.h" #include "../visual/renderman.h" enum message { MSG_ATTACK=0, // offer an attack opportunity to enemies - not if stealthed MSG_JOIN // offer to merge with ally pod // ally - change mission - need help // ally - warning // enemy - diplomatic messages // enemy - threats // enemy - bribes // enemy - bluffs }; class MsgPort { public: MsgPort(Pod* in_pod); ~MsgPort(); void Send(Pod* to, message msg); // send by pointer //Send(int to, message msg); // send by pod ID private: Pod* from; // the pod this message port is fitted to. }; #endif