Fixed issue where you couldn't remove your buffs.

Fixes:

Traceback (most recent call last):
File "scripts/commands/removebuff.py", line 8, in run
buffObj = actor.getBuffByCRC(int(commandString))
AttributeError: 'resources.objects.creature.CreatureObject' object has no attribute 'getBuffByCRC'
This commit is contained in:
Treeku
2014-08-24 02:00:43 +01:00
parent d4a298ed8c
commit 918520052b
+2 -2
View File
@@ -5,11 +5,11 @@ def setup():
def run(core, actor, target, commandString):
buffObj = actor.getBuffByCRC(int(commandString))
buffObj = actor.getBuffList().get(int(commandString))
if buffObj is None:
return
if buffObj.isRemovableByPlayer() and buffObj.isDebuff() is False:
core.buffService.removeBuffFromCreature(actor, buffObj)
return
return