… | |
… | |
386 | /* If we don't have an enemy, do special movement or the like */ |
386 | /* If we don't have an enemy, do special movement or the like */ |
387 | if (!enemy) |
387 | if (!enemy) |
388 | { |
388 | { |
389 | if (QUERY_FLAG (op, FLAG_ONLY_ATTACK)) |
389 | if (QUERY_FLAG (op, FLAG_ONLY_ATTACK)) |
390 | { |
390 | { |
|
|
391 | op->destroy_inv (true); // be explicit about dropping |
391 | op->destroy (); |
392 | op->destroy (true); |
392 | return 1; |
393 | return 1; |
393 | } |
394 | } |
394 | |
395 | |
395 | /* Probably really a bug for a creature to have both |
396 | /* Probably really a bug for a creature to have both |
396 | * stand still and a movement type set. |
397 | * stand still and a movement type set. |
… | |
… | |
650 | if (QUERY_FLAG (part, FLAG_FREED)) /* Might be freed by ghost-attack or hit-back */ |
651 | if (QUERY_FLAG (part, FLAG_FREED)) /* Might be freed by ghost-attack or hit-back */ |
651 | return 1; |
652 | return 1; |
652 | |
653 | |
653 | if (QUERY_FLAG (op, FLAG_ONLY_ATTACK)) |
654 | if (QUERY_FLAG (op, FLAG_ONLY_ATTACK)) |
654 | { |
655 | { |
655 | op->remove (); |
656 | op->destroy_inv (true); // be explicit about dropping |
656 | op->destroy (); |
657 | op->destroy (true); |
657 | return 1; |
658 | return 1; |
658 | } |
659 | } |
|
|
660 | |
659 | return 0; |
661 | return 0; |
660 | } |
662 | } |
661 | |
663 | |
662 | int |
664 | int |
663 | can_hit (object *ob1, object *ob2, rv_vector * rv) |
665 | can_hit (object *ob1, object *ob2, rv_vector * rv) |