|
|
@ -287,12 +287,12 @@ struct product_hook : item_product {
|
|
|
|
std::vector<df::reaction_reagent*> *in_reag,
|
|
|
|
std::vector<df::reaction_reagent*> *in_reag,
|
|
|
|
std::vector<df::item*> *in_items,
|
|
|
|
std::vector<df::item*> *in_items,
|
|
|
|
int32_t quantity, df::job_skill skill,
|
|
|
|
int32_t quantity, df::job_skill skill,
|
|
|
|
df::historical_entity *entity, int32_t unk, df::world_site *site, void* unk2)
|
|
|
|
int32_t quality, df::historical_entity *entity, df::world_site *site, std::vector<void *> *unk2)
|
|
|
|
) {
|
|
|
|
) {
|
|
|
|
color_ostream_proxy out(Core::getInstance().getConsole());
|
|
|
|
color_ostream_proxy out(Core::getInstance().getConsole());
|
|
|
|
auto product = products[this];
|
|
|
|
auto product = products[this];
|
|
|
|
if ( !product ) {
|
|
|
|
if ( !product ) {
|
|
|
|
INTERPOSE_NEXT(produce)(unit, out_products, out_items, in_reag, in_items, quantity, skill, entity, unk, site, unk2);
|
|
|
|
INTERPOSE_NEXT(produce)(unit, out_products, out_items, in_reag, in_items, quantity, skill, quality, entity, site, unk2);
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
df::reaction* this_reaction=product->react;
|
|
|
|
df::reaction* this_reaction=product->react;
|
|
|
@ -304,7 +304,7 @@ struct product_hook : item_product {
|
|
|
|
|
|
|
|
|
|
|
|
size_t out_item_count = out_items->size();
|
|
|
|
size_t out_item_count = out_items->size();
|
|
|
|
|
|
|
|
|
|
|
|
INTERPOSE_NEXT(produce)(unit, out_products, out_items, in_reag, in_items, quantity, skill, entity, unk, site, unk2);
|
|
|
|
INTERPOSE_NEXT(produce)(unit, out_products, out_items, in_reag, in_items, quantity, skill, quality, entity, site, unk2);
|
|
|
|
if ( out_items->size() == out_item_count )
|
|
|
|
if ( out_items->size() == out_item_count )
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
//if it produced something, call the scripts
|
|
|
|
//if it produced something, call the scripts
|
|
|
|