summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Blocks/BlockTorch.h16
-rw-r--r--src/Generating/BioGen.cpp4
2 files changed, 18 insertions, 2 deletions
diff --git a/src/Blocks/BlockTorch.h b/src/Blocks/BlockTorch.h
index 36d2fec67..0a834d13d 100644
--- a/src/Blocks/BlockTorch.h
+++ b/src/Blocks/BlockTorch.h
@@ -119,6 +119,22 @@ public:
// Toches can be placed on the top of these slabs only if the occupy the top half of the voxel
return ((a_BlockFace == BLOCK_FACE_YP) && ((a_BlockMeta & 0x08) == 0x08));
}
+ case E_BLOCK_WOODEN_STAIRS:
+ case E_BLOCK_COBBLESTONE_STAIRS:
+ case E_BLOCK_BRICK_STAIRS:
+ case E_BLOCK_STONE_BRICK_STAIRS:
+ case E_BLOCK_NETHER_BRICK_STAIRS:
+ case E_BLOCK_SANDSTONE_STAIRS:
+ case E_BLOCK_SPRUCE_WOOD_STAIRS:
+ case E_BLOCK_BIRCH_WOOD_STAIRS:
+ case E_BLOCK_JUNGLE_WOOD_STAIRS:
+ case E_BLOCK_QUARTZ_STAIRS:
+ case E_BLOCK_ACACIA_WOOD_STAIRS:
+ case E_BLOCK_DARK_OAK_WOOD_STAIRS:
+ case E_BLOCK_RED_SANDSTONE_STAIRS:
+ {
+ return (a_BlockFace == BLOCK_FACE_TOP) && (a_BlockMeta & E_BLOCK_STAIRS_UPSIDE_DOWN);
+ }
default:
{
if (cBlockInfo::FullyOccupiesVoxel(a_BlockType))
diff --git a/src/Generating/BioGen.cpp b/src/Generating/BioGen.cpp
index f0d2af4f3..ff8827511 100644
--- a/src/Generating/BioGen.cpp
+++ b/src/Generating/BioGen.cpp
@@ -641,8 +641,8 @@ void cBioGenMultiStepMap::BuildTemperatureHumidityMaps(int a_ChunkX, int a_Chunk
// Re-map into integral values in [0 .. 255] range:
for (size_t idx = 0; idx < ARRAYCOUNT(a_TemperatureMap); idx++)
{
- a_TemperatureMap[idx] = std::max(0, std::min(255, static_cast<int>(128 + TemperatureMap[idx] * 128)));
- a_HumidityMap[idx] = std::max(0, std::min(255, static_cast<int>(128 + HumidityMap[idx] * 128)));
+ a_TemperatureMap[idx] = Clamp(static_cast<int>(128 + TemperatureMap[idx] * 128), 0, 255);
+ a_HumidityMap[idx] = Clamp(static_cast<int>(128 + HumidityMap[idx] * 128), 0, 255);
}
}