regrass: ignore furrowed tiles (dirt roads)

develop
Robert Heinrich 2012-04-22 20:25:10 +02:00
parent af12e83ac4
commit 760bc8b09f
1 changed files with 5 additions and 0 deletions

@ -86,6 +86,10 @@ command_result df_regrass (color_ostream &out, vector <string> & parameters)
|| cur->occupancy[x][y].bits.building) || cur->occupancy[x][y].bits.building)
continue; continue;
// don't touch furrowed tiles (dirt roads made on soil)
if(tileSpecial(cur->tiletype[x][y]) == tiletype_special::FURROWED)
continue;
int mat = tileMaterial(cur->tiletype[x][y]); int mat = tileMaterial(cur->tiletype[x][y]);
if ( mat != tiletype_material::SOIL if ( mat != tiletype_material::SOIL
&& mat != tiletype_material::GRASS_DARK // refill existing grass, too && mat != tiletype_material::GRASS_DARK // refill existing grass, too
@ -93,6 +97,7 @@ command_result df_regrass (color_ostream &out, vector <string> & parameters)
) )
continue; continue;
// max = set amounts of all grass events on that tile to 100 // max = set amounts of all grass events on that tile to 100
if(max) if(max)
{ {