summaryrefslogtreecommitdiffstats
path: root/src/Bindings
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2019-09-29 14:59:24 +0200
committerGitHub <noreply@github.com>2019-09-29 14:59:24 +0200
commit365cbc6e1cea96741e26c9ce912b003f8fd2c62c (patch)
treef23682c47928597791c53f3a300b03494ffde417 /src/Bindings
parentCactus can now grow and will be dropped if there is no place to grow. (diff)
downloadcuberite-365cbc6e1cea96741e26c9ce912b003f8fd2c62c.tar
cuberite-365cbc6e1cea96741e26c9ce912b003f8fd2c62c.tar.gz
cuberite-365cbc6e1cea96741e26c9ce912b003f8fd2c62c.tar.bz2
cuberite-365cbc6e1cea96741e26c9ce912b003f8fd2c62c.tar.lz
cuberite-365cbc6e1cea96741e26c9ce912b003f8fd2c62c.tar.xz
cuberite-365cbc6e1cea96741e26c9ce912b003f8fd2c62c.tar.zst
cuberite-365cbc6e1cea96741e26c9ce912b003f8fd2c62c.zip
Diffstat (limited to '')
-rw-r--r--src/Bindings/ManualBindings.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/Bindings/ManualBindings.cpp b/src/Bindings/ManualBindings.cpp
index b8827442c..1ab3cbaa0 100644
--- a/src/Bindings/ManualBindings.cpp
+++ b/src/Bindings/ManualBindings.cpp
@@ -3477,14 +3477,13 @@ static int tolua_cHopperEntity_GetOutputBlockPos(lua_State * tolua_S)
}
NIBBLETYPE a_BlockMeta = static_cast<NIBBLETYPE>(tolua_tonumber(tolua_S, 2, 0));
- int a_OutputX, a_OutputY, a_OutputZ;
- bool res = self->GetOutputBlockPos(a_BlockMeta, a_OutputX, a_OutputY, a_OutputZ);
- tolua_pushboolean(tolua_S, res);
- if (res)
+ auto res = self->GetOutputBlockPos(a_BlockMeta);
+ tolua_pushboolean(tolua_S, res.first);
+ if (res.first)
{
- tolua_pushnumber(tolua_S, static_cast<lua_Number>(a_OutputX));
- tolua_pushnumber(tolua_S, static_cast<lua_Number>(a_OutputY));
- tolua_pushnumber(tolua_S, static_cast<lua_Number>(a_OutputZ));
+ tolua_pushnumber(tolua_S, static_cast<lua_Number>(res.second.x));
+ tolua_pushnumber(tolua_S, static_cast<lua_Number>(res.second.y));
+ tolua_pushnumber(tolua_S, static_cast<lua_Number>(res.second.z));
return 4;
}
return 1;