summaryrefslogtreecommitdiffstats
path: root/src/World.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2014-06-11 14:37:04 +0200
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2014-06-11 14:37:04 +0200
commitf7913d3b742e13595e3ded99820a13ade8a3b674 (patch)
treee35477fc64cec7f1abb952f2529cbff59372e1c5 /src/World.h
parentUpdate APIDesc.lua (diff)
downloadcuberite-f7913d3b742e13595e3ded99820a13ade8a3b674.tar
cuberite-f7913d3b742e13595e3ded99820a13ade8a3b674.tar.gz
cuberite-f7913d3b742e13595e3ded99820a13ade8a3b674.tar.bz2
cuberite-f7913d3b742e13595e3ded99820a13ade8a3b674.tar.lz
cuberite-f7913d3b742e13595e3ded99820a13ade8a3b674.tar.xz
cuberite-f7913d3b742e13595e3ded99820a13ade8a3b674.tar.zst
cuberite-f7913d3b742e13595e3ded99820a13ade8a3b674.zip
Diffstat (limited to 'src/World.h')
-rw-r--r--src/World.h14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/World.h b/src/World.h
index a72904f6a..f9471e881 100644
--- a/src/World.h
+++ b/src/World.h
@@ -710,20 +710,16 @@ public:
/** Returns true if the current weather is sun */
bool IsWeatherSunny(void) const { return (m_Weather == wSunny); }
- /** Returns true if it is sunny at the specified location. This takes into accunt biomes.
- This function is identical to IsWeatherSunny except for two extra parameters that aren't used, but bearbin insists :/
- */
+ /** Returns true if it is sunny at the specified location. This takes into account biomes. */
bool IsWeatherSunnyAt(int a_BlockX, int a_BlockZ) const
{
- UNUSED(a_BlockX);
- UNUSED(a_BlockZ);
- return (m_Weather == wSunny);
+ return (IsWeatherSunny() || IsBiomeNoDownfall(GetBiomeAt(a_BlockX, a_BlockZ)));
}
/** Returns true if the current weather is rain */
bool IsWeatherRain(void) const { return (m_Weather == wRain); }
- /** Returns true if it is raining at the specified location. This takes into accunt biomes. */
+ /** Returns true if it is raining at the specified location. This takes into account biomes. */
bool IsWeatherRainAt (int a_BlockX, int a_BlockZ) const
{
return (m_Weather == wRain) && (!IsBiomeNoDownfall(GetBiomeAt(a_BlockX, a_BlockZ)));
@@ -732,7 +728,7 @@ public:
/** Returns true if the current weather is stormy */
bool IsWeatherStorm(void) const { return (m_Weather == wStorm); }
- /** Returns true if the weather is stormy at the specified location. This takes into accunt biomes. */
+ /** Returns true if the weather is stormy at the specified location. This takes into account biomes. */
bool IsWeatherStormAt(int a_BlockX, int a_BlockZ) const
{
return (m_Weather == wStorm) && (!IsBiomeNoDownfall(GetBiomeAt(a_BlockX, a_BlockZ)));
@@ -741,7 +737,7 @@ public:
/** Returns true if the current weather has any precipitation - rain, storm or snow */
bool IsWeatherWet(void) const { return (m_Weather != wSunny); }
- /** Returns true if it is raining, stormy or snowing at the specified location. This takes into accunt biomes. */
+ /** Returns true if it is raining, stormy or snowing at the specified location. This takes into account biomes. */
bool IsWeatherWetAt(int a_BlockX, int a_BlockZ) const
{
return (m_Weather != wSunny) && (!IsBiomeNoDownfall(GetBiomeAt(a_BlockX, a_BlockZ)));