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

Function setTileMaterial

plugins/fixveins.cpp:29–40  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27REQUIRE_GLOBAL(world);
28
29bool setTileMaterial(df::tiletype &tile, const df::tiletype_material mat)
30{
31 df::tiletype newTile = findTileType(tileShape(tile), mat, tileVariant(tile), tileSpecial(tile), tileDirection(tile));
32 if (newTile == tiletype::Void)
33 return false;
34 if (newTile != tile)
35 {
36 tile = newTile;
37 return true;
38 }
39 return false;
40}
41
42command_result df_fixveins (color_ostream &out, vector <string> & parameters)
43{

Callers 1

df_fixveinsFunction · 0.85

Calls 5

findTileTypeFunction · 0.85
tileShapeFunction · 0.85
tileVariantFunction · 0.85
tileSpecialFunction · 0.85
tileDirectionFunction · 0.85

Tested by

no test coverage detected