I am writing networking-support for my application:
o My server is waiting for incoming data (type: char*).
o When data arrives, the servercode fires an event.
o This event is caught by my networkingmodule which has an eventqueue and computes the received data.
Now I have some questions:
1) My server inherits from iEventOutlet and does the following:
this->netevent = CreateEvent();
this->netevent->Add(XXX);
Post(this->netevent);
what do I have to insert into "XXX"?
I guess I have to use
virtual bool iEvent::Add ( const char * name,
const char * v
)
-> "const char* v" will be my my received data?
what shall "const char* name" be?
2) My networking-module inherits from csBaseEventHandler.
I know I will use one of the several methods to compute my event-data but how do I catch events from the server-code?
There should be a "link" in the code between server and netmodule, but how can I establish it?
3) What is the difference between broadcasts and commands?