[Cleanup] Remove unnecessary conditions in Client::Consume() (#3265)

# Notes
- We check `increase < 0` prior to this, so this can't ever happen.
This commit is contained in:
Alex King 2023-04-05 10:26:32 -04:00 committed by GitHub
parent 3d2f560436
commit 39ce0178f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8355,9 +8355,6 @@ void Client::Consume(const EQ::ItemData *item, uint8 type, int16 slot, bool auto
return; return;
if (type == EQ::item::ItemTypeFood) { if (type == EQ::item::ItemTypeFood) {
if (increase < 0)
return;
m_pp.hunger_level += increase; m_pp.hunger_level += increase;
LogFood("Consuming food, points added to hunger_level: [{}] - current_hunger: [{}]", increase, m_pp.hunger_level); LogFood("Consuming food, points added to hunger_level: [{}] - current_hunger: [{}]", increase, m_pp.hunger_level);
@ -8370,9 +8367,6 @@ void Client::Consume(const EQ::ItemData *item, uint8 type, int16 slot, bool auto
LogFood("Eating from slot: [{}]", (int)slot); LogFood("Eating from slot: [{}]", (int)slot);
} else { } else {
if (increase < 0)
return;
m_pp.thirst_level += increase; m_pp.thirst_level += increase;
DeleteItemInInventory(slot, 1); DeleteItemInInventory(slot, 1);