Disable pathfinding when no geodata are loaded.

This commit is contained in:
MobiusDev 2017-10-20 23:30:05 +00:00
parent 7b86cf9467
commit 38c11f3a55
5 changed files with 60 additions and 20 deletions

View File

@ -107,11 +107,19 @@ public class GeoEngine
_log.info("GeoEngine: Loaded " + loaded + " geodata files.");
// Avoid wrong config when no files loaded
if ((loaded == 0) && (Config.COORD_SYNCHRONIZE == 2))
// avoid wrong configs when no files are loaded
if (loaded == 0)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
if (Config.PATHFINDING)
{
Config.PATHFINDING = false;
_log.info("GeoEngine: Forcing PathFinding setting to false.");
}
if (Config.COORD_SYNCHRONIZE == 2)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
}
}
// release multilayer block temporarily buffer

View File

@ -107,11 +107,19 @@ public class GeoEngine
_log.info("GeoEngine: Loaded " + loaded + " geodata files.");
// Avoid wrong config when no files loaded
if ((loaded == 0) && (Config.COORD_SYNCHRONIZE == 2))
// avoid wrong configs when no files are loaded
if (loaded == 0)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
if (Config.PATHFINDING)
{
Config.PATHFINDING = false;
_log.info("GeoEngine: Forcing PathFinding setting to false.");
}
if (Config.COORD_SYNCHRONIZE == 2)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
}
}
// release multilayer block temporarily buffer

View File

@ -107,11 +107,19 @@ public class GeoEngine
_log.info("GeoEngine: Loaded " + loaded + " geodata files.");
// Avoid wrong config when no files loaded
if ((loaded == 0) && (Config.COORD_SYNCHRONIZE == 2))
// avoid wrong configs when no files are loaded
if (loaded == 0)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
if (Config.PATHFINDING)
{
Config.PATHFINDING = false;
_log.info("GeoEngine: Forcing PathFinding setting to false.");
}
if (Config.COORD_SYNCHRONIZE == 2)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
}
}
// release multilayer block temporarily buffer

View File

@ -105,11 +105,19 @@ public class GeoEngine
_log.info("GeoEngine: Loaded " + loaded + " geodata files.");
// Avoid wrong config when no files loaded
if ((loaded == 0) && (Config.COORD_SYNCHRONIZE == 2))
// avoid wrong configs when no files are loaded
if (loaded == 0)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
if (Config.PATHFINDING)
{
Config.PATHFINDING = false;
_log.info("GeoEngine: Forcing PathFinding setting to false.");
}
if (Config.COORD_SYNCHRONIZE == 2)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
}
}
// release multilayer block temporarily buffer

View File

@ -107,11 +107,19 @@ public class GeoEngine
_log.info("GeoEngine: Loaded " + loaded + " geodata files.");
// Avoid wrong config when no files loaded
if ((loaded == 0) && (Config.COORD_SYNCHRONIZE == 2))
// avoid wrong configs when no files are loaded
if (loaded == 0)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
if (Config.PATHFINDING)
{
Config.PATHFINDING = false;
_log.info("GeoEngine: Forcing PathFinding setting to false.");
}
if (Config.COORD_SYNCHRONIZE == 2)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
}
}
// release multilayer block temporarily buffer