Vehicles fixes

- Fix boats being saved as horses
- Fix first boat/horse not saving property status in scenario map data
- Game finally supports boats that start outdoors... probably
This commit is contained in:
2015-09-03 03:01:34 -04:00
parent d3b0b26deb
commit 9fd65cd597
7 changed files with 79 additions and 24 deletions

View File

@@ -1865,10 +1865,10 @@ void loadOutMapData(map_data&& data, location which, cScenario& scen) {
case eMapFeature::BOAT:
is_boat = true;
case eMapFeature::HORSE:
what = &(is_boat ? scen.boats : scen.horses)[abs(feat.second)];
what = &(is_boat ? scen.boats : scen.horses)[abs(feat.second) - 1];
what->which_town = 200;
what->sector = which;
what->loc_in_sec = loc(x,y);
what->loc = loc(x,y);
what->property = feat.second < 0;
break;
case eMapFeature::FIELD:
@@ -1913,7 +1913,7 @@ void loadTownMapData(map_data&& data, int which, cScenario& scen) {
case eMapFeature::BOAT:
is_boat = true;
case eMapFeature::HORSE:
what = &(is_boat ? scen.boats : scen.horses)[abs(feat.second)];
what = &(is_boat ? scen.boats : scen.horses)[abs(feat.second) - 1];
what->which_town = which;
what->loc = loc(x,y);
what->property = feat.second < 0;