fix #3811: Multiplayer Crash on join

Game was probably being updated with title sequence sprite spatial index.
This commit is contained in:
Ted John 2016-06-03 22:03:22 +01:00
parent a79e793e67
commit a9bf0cdd4e
1 changed files with 10 additions and 1 deletions

View File

@ -16,6 +16,7 @@
#include "../core/Exception.hpp"
#include "../core/IStream.hpp"
#include "../network/network.h"
#include "S6Importer.h"
extern "C"
@ -378,7 +379,15 @@ void S6Importer::Import()
}
reset_loaded_objects();
map_update_tile_pointers();
game_do_command(0, GAME_COMMAND_FLAG_APPLY, 0, 0, GAME_COMMAND_RESET_SPRITES, 0, 0);
if (network_get_mode() == NETWORK_MODE_CLIENT)
{
reset_sprite_spatial_index();
game_do_command(0, GAME_COMMAND_FLAG_APPLY, 0, 0, GAME_COMMAND_RESET_SPRITES, 0, 0);
}
else
{
reset_sprite_spatial_index();
}
game_convert_strings_to_utf8();
if (FixIssues)
{