… | |
… | |
464 | static void |
464 | static void |
465 | adjust_weight (object *op, weight_t sub, weight_t add) |
465 | adjust_weight (object *op, weight_t sub, weight_t add) |
466 | { |
466 | { |
467 | while (op) |
467 | while (op) |
468 | { |
468 | { |
469 | weight_t carrying = op->carrying |
469 | weight_t carrying = (weight_t)op->carrying |
470 | - weight_adjust_for (op, sub); |
470 | - weight_adjust_for (op, sub) |
471 | + weight_adjust_for (op, add); |
471 | + weight_adjust_for (op, add); |
472 | |
472 | |
473 | sub = op->carrying; |
473 | sub = op->carrying; |
474 | op->carrying = carrying; |
474 | op->carrying = carrying; |
475 | add = op->carrying; |
475 | add = op->carrying; |