diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-08-22 19:35:22 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-08-22 19:35:22 +0300 |
commit | 34bd6e0b8e0fb74cc416550a52e6406c47fefea6 (patch) | |
tree | f2e36f2ae2b721de22be4e1b18cf1dd09ba03741 /src/beingequipbackend.cpp | |
parent | 1ee6d71c1d771ab8a990ef427a59f54132910ac7 (diff) | |
download | manaplus-34bd6e0b8e0fb74cc416550a52e6406c47fefea6.tar.gz manaplus-34bd6e0b8e0fb74cc416550a52e6406c47fefea6.tar.bz2 manaplus-34bd6e0b8e0fb74cc416550a52e6406c47fefea6.tar.xz manaplus-34bd6e0b8e0fb74cc416550a52e6406c47fefea6.zip |
Add some missing consts.
Diffstat (limited to 'src/beingequipbackend.cpp')
-rw-r--r-- | src/beingequipbackend.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/beingequipbackend.cpp b/src/beingequipbackend.cpp index 22459cc24..75f135409 100644 --- a/src/beingequipbackend.cpp +++ b/src/beingequipbackend.cpp @@ -41,20 +41,21 @@ BeingEquipBackend::BeingEquipBackend(Being *const being) { const int idx = inventoryHandler-> convertFromServerSlot(CAST_S32(f)); - const int id = being->mSlots[f].spriteId; + const BeingSlot &slot = being->mSlots[f]; + const int id = slot.spriteId; if (id > 0 && idx >= 0 && idx < EQUIPMENT_SIZE) { Item *const item = new Item(id, ItemType::Unknown, 1, 0, - being->mSlots[f].colorId, + slot.colorId, Identified_true, Damaged_false, Favorite_false, Equipm_true, Equipped_true); - const CardsList &cards = being->mSlots[f].cardsId; + const CardsList &cards = slot.cardsId; if (!cards.isEmpty()) item->setCards(&cards.cards[0], maxCards); mEquipment[idx] = item; |