diff options
| author | oroborus <oroborus@0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e> | 2008-07-10 11:28:59 +0000 |
|---|---|---|
| committer | oroborus <oroborus@0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e> | 2008-07-10 11:28:59 +0000 |
| commit | bb15df3f3428df7cd2a4482adebcdaa6fc2f516e (patch) | |
| tree | 61993b5576bebeff7cf9dbcecc5fabdf592abfcc /src/base/modules.c | |
| parent | 0eda3185ba30d433029c9a7e725529a801c93d80 (diff) | |
- precisteny kod sietoveho multiplayera
- moduly si mozu mosielat spravy cez sietovy protokol
- opravy chyb v moduloch
- oprava chyby, v textovych poliach sa zobrazuju znaky, ktore ste nestalcili
- director_t* loadDirector(char *s) vracia NULL ak adresar neexistuje ( predtym sa proces zrutil )
git-svn-id: http://opensvn.csie.org/tuxanci_ng@126 0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e
Diffstat (limited to 'src/base/modules.c')
| -rwxr-xr-x | src/base/modules.c | 31 |
1 files changed, 22 insertions, 9 deletions
diff --git a/src/base/modules.c b/src/base/modules.c index 8b84987..afe192c 100755 --- a/src/base/modules.c +++ b/src/base/modules.c @@ -21,12 +21,6 @@ #include "configFile.h" #endif -int pokus(char *s) -{ - printf("s = %s\n", s); - return 0; -} - static export_fce_t export_fce = { #ifndef PUBLIC_SERVER @@ -37,7 +31,6 @@ static export_fce_t export_fce = .fce_getNetTypeGame = getNetTypeGame, .fce_getTuxProportion = getTuxProportion, .fce_setTuxProportion = setTuxProportion, - //.fce_getTuxID = getTuxID, .fce_actionTux = actionTux, .fce_getMyTime = getMyTime, @@ -46,8 +39,12 @@ static export_fce_t export_fce = .fce_conflictSpace = conflictSpace, .fce_isFreeSpace = isFreeSpace, .fce_findFreeSpace = findFreeSpace, - .fce_proto_send_newtux_server = proto_send_newtux_server, - .fce_proto_send_shot_server = proto_send_shot_server, + + .fce_proto_send_module_server = proto_send_module_server, +#ifndef PUBLIC_SERVER + .fce_proto_send_module_client = proto_send_module_client, +#endif + .fce_destroyShot = destroyShot, .fce_boundBombBall = boundBombBall, .fce_transformOnlyLasser = transformOnlyLasser @@ -101,6 +98,7 @@ static module_t* newModule(char *name) ret->fce_destroy = getFce(ret, "destroy"); ret->fce_isConflict = getFce(ret, "isConflict"); ret->fce_cmd = getFce(ret, "cmdArena"); + ret->fce_recvMsg = getFce(ret, "recvMsg"); printf("load module.. (%s)\n", name); @@ -216,6 +214,21 @@ int isConflictModule(int x, int y, int w, int h) return 0; } +int recvMsgModule(char *msg) +{ + int i; + + for( i = 0 ; i < listModule->count ; i++ ) + { + module_t *this; + + this = (module_t *)listModule->list[i]; + this->fce_recvMsg(msg); + } + + return 0; +} + void quitModule() { destroyListItem(listModule, destroyModule); |