fix bug in multiplayer mode