fix errors under multiplayer mode