Get most of the output for save files implemented, some existing stuff was tweaked

This commit is contained in:
2014-04-20 00:20:36 -04:00
parent 60d1ce3be9
commit 750f876ed1
7 changed files with 230 additions and 139 deletions

View File

@@ -53,3 +53,11 @@ cVehicle& cVehicle::operator = (legacy::boat_record_type& old){
sector.y = old.boat_sector.y;
return *this;
}
void cVehicle::writeTo(std::ostream& file) {
file << "LOCATION " << loc.x << ' ' << loc.y << '\n';
file << "LOCINSECTOR " << loc_in_sec.x << ' ' << loc_in_sec.y << '\n';
file << "SECTOR " << sector.x << ' ' << sector.y << '\n';
file << "IN " << which_town << '\n';
if(property) file << "OWNED\n";
}