… | |
… | |
2809 | * up body locations can be used as restrictions. |
2809 | * up body locations can be used as restrictions. |
2810 | */ |
2810 | */ |
2811 | static object * |
2811 | static object * |
2812 | get_next_item_from_body_location (int loc, object *start) |
2812 | get_next_item_from_body_location (int loc, object *start) |
2813 | { |
2813 | { |
2814 | if (start) |
|
|
2815 | for (object *tmp = start; tmp; tmp = tmp->below) |
2814 | for (object *tmp = start; tmp; tmp = tmp->below) |
2816 | if (tmp->flag [FLAG_APPLIED] |
2815 | if (tmp->flag [FLAG_APPLIED] |
2817 | && tmp->slot[loc].info |
2816 | && tmp->slot[loc].info |
2818 | && !tmp->invisible) |
2817 | && (!tmp->invisible || tmp->type == SKILL)) |
2819 | return tmp; |
2818 | return tmp; |
2820 | |
2819 | |
2821 | return 0; |
2820 | return 0; |
2822 | } |
2821 | } |
2823 | |
2822 | |
2824 | /** |
2823 | /** |
… | |
… | |
2969 | /* This is sort of an error, but happens a lot when old players |
2968 | /* This is sort of an error, but happens a lot when old players |
2970 | * join in with more stuff equipped than they are now allowed. |
2969 | * join in with more stuff equipped than they are now allowed. |
2971 | */ |
2970 | */ |
2972 | LOG (llevError, "Can't find object using location %d on %s\n", i, who->name); |
2971 | LOG (llevError, "Can't find object using location %d on %s\n", i, who->name); |
2973 | #endif |
2972 | #endif |
|
|
2973 | fprintf (stderr, "can apply never due to %d but %d - %d + %d\n",//D |
|
|
2974 | i, who->slot[i].used,ws ? ws->slot[i].info :-77,op->slot[i].info);//D |
2974 | retval |= CAN_APPLY_NEVER; |
2975 | retval |= CAN_APPLY_NEVER; |
2975 | } |
2976 | } |
2976 | else |
2977 | else |
2977 | { |
2978 | { |
2978 | /* need to unapply something. However, if this something |
2979 | /* need to unapply something. However, if this something |