reaction-gloves: fix warnings

develop
lethosor 2020-07-17 00:00:57 -04:00
parent 56e43a0dde
commit c858f33f61
No known key found for this signature in database
GPG Key ID: 76A269552F4F58C1
1 changed files with 3 additions and 3 deletions

@ -22,7 +22,7 @@ struct reaction_gloves_hook : df::reaction_product_itemst {
// Examine creator unit's body plan, see how many hands it has // Examine creator unit's body plan, see how many hands it has
// Count left hands and right hands, as well as "neutral" hands for compatibility // Count left hands and right hands, as well as "neutral" hands for compatibility
int num_hands = 0, num_left = 0, num_right = 0; int num_hands = 0, num_left = 0, num_right = 0;
for (int i = 0; i < unit->body.body_plan->body_parts.size(); i++) for (size_t i = 0; i < unit->body.body_plan->body_parts.size(); i++)
{ {
df::body_part_raw *part = unit->body.body_plan->body_parts[i]; df::body_part_raw *part = unit->body.body_plan->body_parts[i];
if (part->flags.is_set(df::body_part_raw_flags::GRASP)) if (part->flags.is_set(df::body_part_raw_flags::GRASP))
@ -57,7 +57,7 @@ struct reaction_gloves_hook : df::reaction_product_itemst {
num_right *= quantity; num_right *= quantity;
// Iterate across the output gloves, set their handedness, then append them to the actual out_items list for DF // Iterate across the output gloves, set their handedness, then append them to the actual out_items list for DF
for (int i = 0; i < out_items_temp.size(); i++) for (size_t i = 0; i < out_items_temp.size(); i++)
{ {
// Do left gloves first, then right gloves, then "neutral" ones last // Do left gloves first, then right gloves, then "neutral" ones last
// This is important for the "createitem" plugin, which contains similar workaround logic // This is important for the "createitem" plugin, which contains similar workaround logic
@ -76,4 +76,4 @@ struct reaction_gloves_hook : df::reaction_product_itemst {
} }
}; };
IMPLEMENT_VMETHOD_INTERPOSE(reaction_gloves_hook, produce); IMPLEMENT_VMETHOD_INTERPOSE(reaction_gloves_hook, produce);