… | |
… | |
708 | |
708 | |
709 | tmp->destroy (); |
709 | tmp->destroy (); |
710 | op->update_stats (); |
710 | op->update_stats (); |
711 | return; |
711 | return; |
712 | } |
712 | } |
713 | |
|
|
714 | /* If SAVE_INTERVAL is commented out, we never want to save |
|
|
715 | * the player here. |
|
|
716 | */ |
|
|
717 | #ifdef SAVE_INTERVAL |
|
|
718 | /* I'm not sure why there is a value check - since the save |
|
|
719 | * is done every SAVE_INTERVAL seconds, why care the value |
|
|
720 | * of what he is dropping? |
|
|
721 | */ |
|
|
722 | if (op->type == PLAYER && !QUERY_FLAG (tmp, FLAG_UNPAID) && |
|
|
723 | (tmp->nrof ? tmp->value * tmp->nrof : tmp->value > 2000) && (op->contr->last_save_time + SAVE_INTERVAL) <= time (NULL)) |
|
|
724 | { |
|
|
725 | op->contr->save (); |
|
|
726 | op->contr->last_save_time = time (NULL); |
|
|
727 | } |
|
|
728 | #endif /* SAVE_INTERVAL */ |
|
|
729 | |
713 | |
730 | if (op->type == PLAYER) |
714 | if (op->type == PLAYER) |
731 | esrv_del_item (op->contr, tmp->count); |
715 | esrv_del_item (op->contr, tmp->count); |
732 | |
716 | |
733 | /* Call this before we update the various windows/players. At least |
717 | /* Call this before we update the various windows/players. At least |