public static void AddBuff(string buffName, float duration, byte stacks, BuffType buffType, IObjAiBase onto, IObjAiBase from) { var buff = new Buff(_game, buffName, duration, stacks, buffType, onto, from); onto.AddBuff(buff); _game.PacketNotifier.NotifyAddBuff(buff); }
public static IBuff AddBuff(string buffName, float duration, byte stacks, ISpell originspell, IObjAiBase onto, IObjAiBase from, bool infiniteduration = false) { IBuff buff; try { buff = new Buff(_game, buffName, duration, stacks, originspell, onto, from, infiniteduration); } catch (ArgumentException exception) { _logger.Error(exception); return(null); } onto.AddBuff(buff); return(buff); }