summaryrefslogtreecommitdiffstats
path: root/src/Bindings/PluginLua.cpp
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2014-07-03 17:49:21 +0200
committermadmaxoft <github@xoft.cz>2014-07-03 17:49:21 +0200
commit2dbed03cbce873d8a6582bfdc5c4b826b6e7eade (patch)
treec95173c315bbd1020301188b138d426fa800b5d2 /src/Bindings/PluginLua.cpp
parentCMake: Changed slash format to support MSYS. (diff)
downloadcuberite-2dbed03cbce873d8a6582bfdc5c4b826b6e7eade.tar
cuberite-2dbed03cbce873d8a6582bfdc5c4b826b6e7eade.tar.gz
cuberite-2dbed03cbce873d8a6582bfdc5c4b826b6e7eade.tar.bz2
cuberite-2dbed03cbce873d8a6582bfdc5c4b826b6e7eade.tar.lz
cuberite-2dbed03cbce873d8a6582bfdc5c4b826b6e7eade.tar.xz
cuberite-2dbed03cbce873d8a6582bfdc5c4b826b6e7eade.tar.zst
cuberite-2dbed03cbce873d8a6582bfdc5c4b826b6e7eade.zip
Diffstat (limited to 'src/Bindings/PluginLua.cpp')
-rw-r--r--src/Bindings/PluginLua.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/Bindings/PluginLua.cpp b/src/Bindings/PluginLua.cpp
index 344031995..104380ea4 100644
--- a/src/Bindings/PluginLua.cpp
+++ b/src/Bindings/PluginLua.cpp
@@ -1347,18 +1347,15 @@ bool cPluginLua::OnWeatherChanging(cWorld & a_World, eWeather & a_NewWeather)
{
cCSLock Lock(m_CriticalSection);
bool res = false;
- int NewWeather = a_NewWeather;
cLuaRefs & Refs = m_HookMap[cPluginManager::HOOK_WEATHER_CHANGING];
for (cLuaRefs::iterator itr = Refs.begin(), end = Refs.end(); itr != end; ++itr)
{
- m_LuaState.Call((int)(**itr), &a_World, NewWeather, cLuaState::Return, res, NewWeather);
+ m_LuaState.Call((int)(**itr), &a_World, a_NewWeather, cLuaState::Return, res, a_NewWeather);
if (res)
{
- a_NewWeather = (eWeather)NewWeather;
return true;
}
}
- a_NewWeather = (eWeather)NewWeather;
return false;
}