summaryrefslogtreecommitdiff
path: root/src/game-server/item.cpp
diff options
context:
space:
mode:
authorErik Schilling <ablu.erikschilling@googlemail.com>2013-04-27 21:09:23 +0200
committerErik Schilling <ablu.erikschilling@googlemail.com>2013-08-26 22:56:46 +0200
commitf31277b327df701361391b1d4b8bd6f89f4e3109 (patch)
tree0fd2b85c13cb11654ff6cd027e0be7ff6b61c2d6 /src/game-server/item.cpp
parent960d40d819afb65387469591bdb02e6819d72294 (diff)
downloadmanaserv-f31277b327df701361391b1d4b8bd6f89f4e3109.tar.gz
manaserv-f31277b327df701361391b1d4b8bd6f89f4e3109.tar.bz2
manaserv-f31277b327df701361391b1d4b8bd6f89f4e3109.tar.xz
manaserv-f31277b327df701361391b1d4b8bd6f89f4e3109.zip
[Abilities] Removed the old autoattack system
As a side effect i had to remove the monster attack AI for now. I will readd this as next thing.
Diffstat (limited to 'src/game-server/item.cpp')
-rw-r--r--src/game-server/item.cpp28
1 files changed, 0 insertions, 28 deletions
diff --git a/src/game-server/item.cpp b/src/game-server/item.cpp
index 444576f2..589fc011 100644
--- a/src/game-server/item.cpp
+++ b/src/game-server/item.cpp
@@ -22,10 +22,8 @@
#include "game-server/item.h"
#include "common/configuration.h"
-#include "game-server/attack.h"
#include "game-server/attributemanager.h"
#include "game-server/being.h"
-#include "game-server/combatcomponent.h"
#include "game-server/state.h"
#include "scripting/script.h"
#include "scripting/scriptmanager.h"
@@ -53,17 +51,6 @@ void ItemEffectAttrMod::dispell(Entity *itemUser)
mId, !mDuration);
}
-bool ItemEffectAttack::apply(Entity *itemUser)
-{
- itemUser->getComponent<CombatComponent>()->addAttack(mAttackInfo);
- return false;
-}
-
-void ItemEffectAttack::dispell(Entity *itemUser)
-{
- itemUser->getComponent<CombatComponent>()->removeAttack(mAttackInfo);
-}
-
ItemEffectScript::~ItemEffectScript()
{
}
@@ -110,13 +97,6 @@ ItemClass::~ItemClass()
delete mEffects.begin()->second;
mEffects.erase(mEffects.begin());
}
-
- for (std::vector<AttackInfo *>::iterator it = mAttackInfos.begin(),
- it_end = mAttackInfos.end();
- it != it_end; ++it)
- {
- delete *it;
- }
}
void ItemClass::addEffect(ItemEffectInfo *effect,
@@ -148,14 +128,6 @@ bool ItemClass::useTrigger(Entity *itemUser, ItemTriggerType trigger)
return ret;
}
-void ItemClass::addAttack(AttackInfo *attackInfo,
- ItemTriggerType applyTrigger,
- ItemTriggerType dispellTrigger)
-{
- mAttackInfos.push_back(attackInfo);
- addEffect(new ItemEffectAttack(attackInfo), applyTrigger, dispellTrigger);
-}
-
ItemComponent::ItemComponent(ItemClass *type, int amount) :
mType(type),
mAmount(amount)