diff options
Diffstat (limited to 'src/screen_world.c')
| -rw-r--r-- | src/screen_world.c | 41 |
1 files changed, 22 insertions, 19 deletions
diff --git a/src/screen_world.c b/src/screen_world.c index 4f1e8d8..de2d591 100644 --- a/src/screen_world.c +++ b/src/screen_world.c @@ -110,24 +110,6 @@ void countRoundInc() } } -static tux_t* getControlTux(int control_type) -{ - tux_t *thisTux; - int i; - - for( i = 0 ; i < arena->listTux->count ; i++ ) - { - thisTux = (tux_t *)(arena->listTux->list[i]); - - if( thisTux->control == control_type ) - { - return thisTux; - } - } - - return NULL; -} - void prepareArena() { tux_t *tux; @@ -201,7 +183,7 @@ static void netAction(tux_t *tux, int action) { if( getSettingGameType() == NET_GAME_TYPE_SERVER ) { - proto_send_event_server(PROTO_SEND_ALL, NULL, tux , action); + proto_send_event_server(PROTO_SEND_ALL_SEES_TUX, NULL, tux , action); } if( getSettingGameType() == NET_GAME_TYPE_CLIENT ) @@ -409,6 +391,27 @@ static void eventEnd() } } +tux_t* getControlTux(int control_type) +{ + arena_t *arena; + tux_t *thisTux; + int i; + + arena = getCurrentArena(); + + for( i = 0 ; i < arena->listTux->count ; i++ ) + { + thisTux = (tux_t *)(arena->listTux->list[i]); + + if( thisTux->control == control_type ) + { + return thisTux; + } + } + + return NULL; +} + void tuxControl(tux_t *p) { assert( p != NULL ); |