diff options
| author | oroborus <oroborus@0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e> | 2008-03-30 16:51:15 +0000 |
|---|---|---|
| committer | oroborus <oroborus@0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e> | 2008-03-30 16:51:15 +0000 |
| commit | 617ba439aab5f1798eb02618dfcfbed80a5baf28 (patch) | |
| tree | 13df71c96bd302f066406644f20ddd0e58490ded /src/proto.c | |
| parent | b4db5fe1a7c0145c2437cb2f117a2ae59d4e8025 (diff) | |
- polozky casovaca sa nachadzaju v zozname list_t , ktory he sucastou arena_t
- pri bonuse neviditelnost sa neda podvadzat modifikovanim clienta
- o vystreli sa stara server, ich suradnicu a dalsie info posiela server clientom
- parametre sa pisu vo forme --env=val
git-svn-id: http://opensvn.csie.org/tuxanci_ng@38 0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e
Diffstat (limited to 'src/proto.c')
| -rw-r--r-- | src/proto.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/proto.c b/src/proto.c index 38f8ee0..bb1a14c 100644 --- a/src/proto.c +++ b/src/proto.c @@ -265,11 +265,23 @@ void proto_recv_event_server(client_t *client, char *msg) void proto_send_newtux_server(int type, client_t *client, tux_t *tux) { char msg[STR_PROTO_SIZE]; + int x, y; assert( tux != NULL ); + if( tux->bonus == BONUS_HIDDEN ) + { + x = -100; + y = -100; + } + else + { + x = tux->x; + y = tux->y; + } + sprintf(msg, "newtux %d %d %d %d %d %d %d %s %d %d %d %d %d %d %d %d %d %d %d\n", - tux->id ,tux->x, tux->y, tux->status, tux->position ,tux->frame, tux->score, tux->name, + tux->id ,x, y, tux->status, tux->position ,tux->frame, tux->score, tux->name, tux->gun, tux->bonus, tux->shot[GUN_SIMPLE], tux->shot[GUN_DUAL_SIMPLE], tux->shot[GUN_SCATTER], tux->shot[GUN_TOMMY], tux->shot[GUN_LASSER], tux->shot[GUN_MINE], tux->shot[GUN_BOMBBALL], @@ -310,6 +322,7 @@ void proto_recv_newtux_client(char *msg) } tux->id = id; + tux->x = x; tux->y = y; tux->status = status; |