From df2167ead97605708a179032f90605451524df90 Mon Sep 17 00:00:00 2001 From: KimLS Date: Thu, 5 Jun 2014 01:16:44 -0700 Subject: [PATCH] Potential fix for bad water map generation --- awater/water_map.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/awater/water_map.cpp b/awater/water_map.cpp index 23355f2..ec31072 100644 --- a/awater/water_map.cpp +++ b/awater/water_map.cpp @@ -77,6 +77,28 @@ bool WaterMap::BuildAndWriteS3D(std::string zone_name) { } else if (!strncmp(region->GetName().c_str(), "VWA", 3)) { region_type = RegionTypeVWater; + } else { + if (!strncmp(region->GetExtendedInfo().c_str(), "WT", 2)) { + region_type = RegionTypeWater; + } + else if (!strncmp(region->GetExtendedInfo().c_str(), "LA", 2)) { + region_type = RegionTypeLava; + } + else if (!strncmp(region->GetExtendedInfo().c_str(), "DRNTP", 5)) { + region_type = RegionTypeZoneLine; + } + else if (!strncmp(region->GetExtendedInfo().c_str(), "DRP_", 4)) { + region_type = RegionTypePVP; + } + else if (!strncmp(region->GetExtendedInfo().c_str(), "SL", 2)) { + region_type = RegionTypeSlime; + } + else if (!strncmp(region->GetExtendedInfo().c_str(), "DRN", 3)) { + region_type = RegionTypeIce; + } + else if (!strncmp(region->GetExtendedInfo().c_str(), "VWA", 3)) { + region_type = RegionTypeVWater; + } } for(size_t j = 0; j < regions.size(); ++j) {