diff options
author | Erik Schilling <ablu.erikschilling@googlemail.com> | 2013-02-03 09:48:41 +0100 |
---|---|---|
committer | Erik Schilling <ablu.erikschilling@googlemail.com> | 2013-02-04 16:15:12 +0100 |
commit | a114390b372352383241816a29f9c35a368cd4f9 (patch) | |
tree | a99d25002b095ba1d125d97a53baee56be46037c /src/game-server/attribute.cpp | |
parent | 5ba4dbb62d8e5ef86dbd58803cd77268e13f48ce (diff) | |
download | manaserv-a114390b372352383241816a29f9c35a368cd4f9.tar.gz manaserv-a114390b372352383241816a29f9c35a368cd4f9.tar.bz2 manaserv-a114390b372352383241816a29f9c35a368cd4f9.tar.xz manaserv-a114390b372352383241816a29f9c35a368cd4f9.zip |
Random cleanup of attribute code
Did this during trying to understand the code
Diffstat (limited to 'src/game-server/attribute.cpp')
-rw-r--r-- | src/game-server/attribute.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/game-server/attribute.cpp b/src/game-server/attribute.cpp index 3d0f5510..71e5d944 100644 --- a/src/game-server/attribute.cpp +++ b/src/game-server/attribute.cpp @@ -249,16 +249,17 @@ bool AttributeModifiersEffect::recalculateModifiedValue(double newPrevLayerValue bool Attribute::add(unsigned short duration, double value, - unsigned layer, int level) + unsigned layer, int id) { assert(mMods.size() > layer); - LOG_DEBUG("Adding modifier to attribute with duration " << duration << - ", value " << value << ", at layer " << layer << " with id " - << level); + LOG_DEBUG("Adding modifier to attribute with duration " << duration + << ", value " << value + << ", at layer " << layer + << " with id " << id); if (mMods.at(layer)->add(duration, value, (layer ? mMods.at(layer - 1)->getCachedModifiedValue() : mBase) - , level)) + , id)) { while (++layer < mMods.size()) { |