Skip to content

Commit

Permalink
Getv3intfield: Fix logic of return bool
Browse files Browse the repository at this point in the history
  • Loading branch information
paramat committed Mar 9, 2018
1 parent cbb9301 commit 1a88c4b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/script/common/c_converter.h
Expand Up @@ -66,9 +66,9 @@ bool getv3intfield(lua_State *L, int index,
lua_getfield(L, index, fieldname);
bool got = false;
if (lua_istable(L, -1)) {
got = getintfield(L, index, "x", result.X) ||
getintfield(L, index, "y", result.Y) ||
getintfield(L, index, "z", result.Z);
got |= getintfield(L, -1, "x", result.X);
got |= getintfield(L, -1, "y", result.Y);
got |= getintfield(L, -1, "z", result.Z);
}
lua_pop(L, 1);
return got;
Expand Down

0 comments on commit 1a88c4b

Please sign in to comment.