diff options
author | Mattes D <github@xoft.cz> | 2020-04-14 16:43:21 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-14 16:43:21 +0200 |
commit | c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e (patch) | |
tree | 7d7ba1d772d1f4994773f325046a4e6229c91d16 /src/Bindings/ManualBindings_BlockArea.cpp | |
parent | Pressure plate sounds and delay (#4643) (diff) | |
download | cuberite-c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e.tar cuberite-c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e.tar.gz cuberite-c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e.tar.bz2 cuberite-c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e.tar.lz cuberite-c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e.tar.xz cuberite-c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e.tar.zst cuberite-c9a9b3c9d0d4fed0b02d9935923bfd7dcbc45d1e.zip |
Diffstat (limited to 'src/Bindings/ManualBindings_BlockArea.cpp')
-rw-r--r-- | src/Bindings/ManualBindings_BlockArea.cpp | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/Bindings/ManualBindings_BlockArea.cpp b/src/Bindings/ManualBindings_BlockArea.cpp index 9958ec3af..026e9bf2d 100644 --- a/src/Bindings/ManualBindings_BlockArea.cpp +++ b/src/Bindings/ManualBindings_BlockArea.cpp @@ -48,14 +48,10 @@ static int readCuboidOverloadParams(cLuaState & a_LuaState, int a_StartParam, cC else { // Assume the 2-Vector3i version: - Vector3i * p1; - Vector3i * p2; - if (!a_LuaState.GetStackValues(a_StartParam, p1, p2)) + if (!a_LuaState.GetStackValues(a_StartParam, a_Cuboid.p1, a_Cuboid.p2)) { return a_LuaState.ApiParamError("Cannot read the bounds parameter, expected two Vector3i instances"); } - a_Cuboid.p1 = *p1; - a_Cuboid.p2 = *p2; return a_StartParam + 2; } } @@ -85,12 +81,10 @@ static int readVector3iOverloadParams(cLuaState & a_LuaState, int a_StartParam, else { // Assume the Vector3i version: - Vector3i * c; - if (!a_LuaState.GetStackValues(a_StartParam, c)) + if (!a_LuaState.GetStackValues(a_StartParam, a_Coords)) { return a_LuaState.ApiParamError("Cannot read the %s, expected a Vector3i instance", a_ParamName); } - a_Coords = *c; return a_StartParam + 1; } } |