(svn r12129) -Change [FS#1759]: simplified patch settings for pathfinders (Yorick)

This commit is contained in:
smatz
2008-02-13 14:21:36 +00:00
parent 3abf3e3fa4
commit a3e3cd7d46
11 changed files with 81 additions and 40 deletions

View File

@@ -2398,6 +2398,25 @@ bool AfterLoadGame()
}
}
}
/* Convert old PF settings to new */
if (_patches.yapf.rail_use_yapf) {
_patches.pathfinder_for_trains = VPF_YAPF;
} else {
_patches.pathfinder_for_trains = (_patches.new_pathfinding_all ? VPF_NPF : VPF_NTP);
}
if (_patches.yapf.road_use_yapf) {
_patches.pathfinder_for_roadvehs = VPF_YAPF;
} else {
_patches.pathfinder_for_roadvehs = (_patches.new_pathfinding_all ? VPF_NPF : VPF_OPF);
}
if (_patches.yapf.ship_use_yapf) {
_patches.pathfinder_for_ships = VPF_YAPF;
} else {
_patches.pathfinder_for_ships = (_patches.new_pathfinding_all ? VPF_NPF : VPF_OPF);
}
}
return InitializeWindowsAndCaches();