summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2007-01-15 16:31:46 +0000
committerbelugas <belugas@openttd.org>2007-01-15 16:31:46 +0000
commit7b9379e0deea3e4b6e20361abceab31ce5550fd2 (patch)
tree127082a5552f4e89003f028715291430ab11f8e6
parent05b783e551102127f1e48aa579a58b9a1ec8fabb (diff)
downloadopenttd-7b9379e0deea3e4b6e20361abceab31ce5550fd2.tar.xz
(svn r8145) -Featurette: Allow for Tropic Farm to plant fields after producing cargo, like its counterpart in temperate climate.
-rw-r--r--src/industry_cmd.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/industry_cmd.cpp b/src/industry_cmd.cpp
index fe9b3d580..49ceab815 100644
--- a/src/industry_cmd.cpp
+++ b/src/industry_cmd.cpp
@@ -750,7 +750,7 @@ static const byte _plantfarmfield_type[] = {1, 1, 1, 1, 1, 3, 3, 4, 4, 4, 5, 5,
static bool IsBadFarmFieldTile(TileIndex tile)
{
switch (GetTileType(tile)) {
- case MP_CLEAR: return IsClearGround(tile, CLEAR_FIELDS) || IsClearGround(tile, CLEAR_SNOW);
+ case MP_CLEAR: return IsClearGround(tile, CLEAR_FIELDS) || IsClearGround(tile, CLEAR_SNOW) || IsClearGround(tile, CLEAR_DESERT);
case MP_TREES: return false;
default: return true;
}
@@ -759,7 +759,7 @@ static bool IsBadFarmFieldTile(TileIndex tile)
static bool IsBadFarmFieldTile2(TileIndex tile)
{
switch (GetTileType(tile)) {
- case MP_CLEAR: return IsClearGround(tile, CLEAR_SNOW);
+ case MP_CLEAR: return IsClearGround(tile, CLEAR_SNOW) || IsClearGround(tile, CLEAR_DESERT);
case MP_TREES: return false;
default: return true;
}
@@ -960,7 +960,7 @@ static void ProduceIndustryGoods(Industry *i)
i->cargo_waiting[0] = min(0xffff, i->cargo_waiting[0] + i->production_rate[0]);
i->cargo_waiting[1] = min(0xffff, i->cargo_waiting[1] + i->production_rate[1]);
- if (i->type == IT_FARM) {
+ if (i->type == IT_FARM || i->type == IT_FARM_2) {
MaybePlantFarmField(i);
} else if (i->type == IT_LUMBER_MILL && (i->counter & 0x1FF) == 0) {
ChopLumberMillTrees(i);