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

Method getToken

library/modules/Items.cpp:152–159  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

150}
151
152string ItemTypeInfo::getToken() {
153 string rv = ENUM_KEY_STR(item_type, type);
154 if (custom)
155 rv += ":" + custom->id;
156 else if (subtype != -1 && type != item_type::PLANT_GROWTH)
157 rv += fmt::format(":{}", subtype);
158 return rv;
159}
160
161string ItemTypeInfo::toString()
162{ using namespace df::enums::item_type;

Callers 15

dfhack_matinfo_getTokenFunction · 0.45
changeitem_executeFunction · 0.45
print_mineral_statsMethod · 0.45
scan_block_tilesMethod · 0.45
form_veinsMethod · 0.45
place_orphanMethod · 0.45
place_veinsMethod · 0.45
df_createitemFunction · 0.45
changelayerFunction · 0.45
df_probeFunction · 0.45
tiletypes.cppFile · 0.45
orders_export_commandFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected