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

Function find_reagent

plugins/add-spatter.cpp:283–297  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

281 */
282
283static void find_reagent(
284 color_ostream &out, ReagentSource &info, df::reaction *react, std::string name
285) {
286 for (size_t i = 0; i < react->reagents.size(); i++)
287 {
288 if (react->reagents[i]->code != name)
289 continue;
290
291 info.idx = i;
292 info.reagent = react->reagents[i];
293 return;
294 }
295
296 out.printerr("Invalid reagent name '{}' in '{}'\n", name, react->code);
297}
298
299static void parse_product(
300 color_ostream &out, ProductInfo &info, df::reaction *react, improvement_product *prod

Callers 1

parse_productFunction · 0.85

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected