| 141 | void dfhack_printerr(lua_State *S, const string &str); |
| 142 | |
| 143 | static df::coord2d CheckCoordXY(lua_State *state, int base, bool vararg = false) |
| 144 | { |
| 145 | df::coord2d p; |
| 146 | if (vararg && lua_gettop(state) <= base) |
| 147 | Lua::CheckDFAssign(state, &p, base); |
| 148 | else |
| 149 | { |
| 150 | p = df::coord2d( |
| 151 | luaL_checkint(state, base), |
| 152 | luaL_checkint(state, base+1) |
| 153 | ); |
| 154 | } |
| 155 | return p; |
| 156 | } |
| 157 | |
| 158 | static df::coord CheckCoordXYZ(lua_State *state, int base, bool vararg = false) |
| 159 | { |
no test coverage detected