MCPcopy Create free account
hub / github.com/DFHack/dfhack / dig_now_tile

Function dig_now_tile

plugins/dig-now.cpp:1064–1083  ·  view source on GitHub ↗

runs dig-now for the specified tile coordinate. default options apply.

Source from the content-addressed store, hash-verified

1062
1063// runs dig-now for the specified tile coordinate. default options apply.
1064static int dig_now_tile(lua_State *L)
1065{
1066 DFCoord pos;
1067 if (lua_gettop(L) <= 1)
1068 Lua::CheckDFAssign(L, &pos, 1);
1069 else
1070 pos = DFCoord(luaL_checkint(L, 1), luaL_checkint(L, 2),
1071 luaL_checkint(L, 3));
1072
1073 color_ostream *out = Lua::GetOutput(L);
1074 if (!out)
1075 out = &Core::getInstance().getConsole();
1076
1077 dig_now_options options;
1078 options.start = pos;
1079 options.end = pos;
1080 lua_pushboolean(L, dig_now_impl(*out, options));
1081
1082 return 1;
1083}
1084
1085static int link_adjacent_smooth_walls(lua_State *L)
1086{

Callers

nothing calls this directly

Calls 4

lua_gettopFunction · 0.85
CheckDFAssignFunction · 0.85
lua_pushbooleanFunction · 0.85
dig_now_implFunction · 0.85

Tested by

no test coverage detected