diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/map/pc.c | 5 | ||||
-rw-r--r-- | src/map/skill.c | 19 |
2 files changed, 0 insertions, 24 deletions
diff --git a/src/map/pc.c b/src/map/pc.c index e181b5f89..5d87d017d 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -5295,11 +5295,6 @@ static int pc_useitem(struct map_session_data *sd, int n) if(sd->catch_target_class != -1) //Abort pet catching. sd->catch_target_class = -1; - // Unset auto-cast related data for items of type IT_DELAYCONSUME or the item won't be consumed. - // TODO: Check if this is still required. [Kenpachi] - if (sd->inventory_data[n]->flag.delay_consume != 0) - sd->autocast.type = AUTOCAST_NONE; - amount = sd->status.inventory[n].amount; //Check if the item is to be consumed immediately [Skotlex] if (sd->inventory_data[n]->flag.delay_consume || sd->inventory_data[n]->flag.keepafteruse) diff --git a/src/map/skill.c b/src/map/skill.c index 6fc1b80a2..e779e9859 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -14095,25 +14095,6 @@ static int skill_check_condition_castbegin(struct map_session_data *sd, uint16 s if( !sc->count ) sc = NULL; - // TODO: Check if the validation of delayed consume is still required. (See the delayed consume related TODO in pc_useitem().) - if (sd->autocast.type == AUTOCAST_ITEM) { - int i = sd->itemindex; - - if (i == INDEX_NOT_FOUND || sd->status.inventory[i].nameid != sd->itemid || sd->inventory_data[i] == NULL - || sd->status.inventory[i].amount < 1) { // Something went wrong. Item exploit? - sd->itemid = INDEX_NOT_FOUND; - sd->itemindex = INDEX_NOT_FOUND; - return 0; - } - - // Consume the item. Rental usable items are not consumed until expiration. - if (sd->status.inventory[i].expire_time == 0 && sd->inventory_data[i]->flag.delay_consume == 1) - pc->delitem(sd, i, 1, 0, DELITEM_NORMAL, LOG_TYPE_CONSUME); - - sd->itemid = INDEX_NOT_FOUND; - sd->itemindex = INDEX_NOT_FOUND; - } - if (pc_is90overweight(sd) && sd->autocast.type != AUTOCAST_ITEM) { // Skill casting items ignore the overweight restriction. clif->skill_fail(sd, skill_id, USESKILL_FAIL_WEIGHTOVER, 0, 0); return 0; |