Fix remaining issues

develop
Quietust 2012-02-13 19:56:55 -06:00
parent d15d38d536
commit b152a40e83
2 changed files with 3 additions and 3 deletions

@ -74,7 +74,7 @@ namespace DFHack
// Run through until perfect match found or hit end. // Run through until perfect match found or hit end.
FOR_ENUM_ITEMS(tiletype, tt) FOR_ENUM_ITEMS(tiletype, tt)
{ {
if (value < (8|4|1)) if (value == (8|4|1))
break; break;
if (tileShape(tt) == tshape) if (tileShape(tt) == tshape)
{ {

@ -107,9 +107,9 @@ DFhackCExport command_result df_getplants (Core * c, vector <string> & parameter
} }
df::tiletype_shape shape = tileShape(cur->tiletype[x][y]); df::tiletype_shape shape = tileShape(cur->tiletype[x][y]);
df::tiletype_special special = tileSpecial(cur->tiletype[x][y]); df::tiletype_special special = tileSpecial(cur->tiletype[x][y]);
if (plant->flags.bits.is_shrub && (treesonly || (shape != tiletype_shape::SHRUB && special != tiletype_special::DEAD))) if (plant->flags.bits.is_shrub && (treesonly || !(shape == tiletype_shape::SHRUB && special != tiletype_special::DEAD)))
continue; continue;
if (!plant->flags.bits.is_shrub && (shrubsonly || shape != tiletype_shape::TREE)) if (!plant->flags.bits.is_shrub && (shrubsonly || !(shape == tiletype_shape::TREE)))
continue; continue;
if (cur->designation[x][y].bits.hidden) if (cur->designation[x][y].bits.hidden)
continue; continue;