Core/CreatureTexts: Added new field SoundPlayType to enable usage of ObjectSounds within creature_text

Port From (https://github.com/TrinityCore/TrinityCore/commit/437fb2aaba8850dd81a15d661c82403be9170c4e)
This commit is contained in:
hondacrx
2021-11-02 14:00:01 -04:00
parent 55746b1007
commit 6f27d79873
6 changed files with 61 additions and 19 deletions
+3 -2
View File
@@ -16,6 +16,7 @@
*/
using Framework.Constants;
using Game;
using Game.Entities;
using Game.Maps;
using Game.Scripting;
@@ -1071,9 +1072,9 @@ namespace Scripts.Spells.Quest
Creature trigger = target.FindNearestCreature(CreatureIds.IceSpikeBunny, 25.0f);
if (trigger)
{
Global.CreatureTextMgr.SendChat(trigger, Misc.Say1, target, ChatMsg.Addon, Language.Addon, Game.CreatureTextRange.Normal, 0, Team.Other, false, target);
Global.CreatureTextMgr.SendChat(trigger, Misc.Say1, target, ChatMsg.Addon, Language.Addon, Game.CreatureTextRange.Normal, 0, SoundKitPlayType.Normal, Team.Other, false, target);
target.KilledMonsterCredit(CreatureIds.Killcredit);
Global.CreatureTextMgr.SendChat(trigger, Misc.Say2, target, ChatMsg.Addon, Language.Addon, Game.CreatureTextRange.Normal, 0, Team.Other, false, target);
Global.CreatureTextMgr.SendChat(trigger, Misc.Say2, target, ChatMsg.Addon, Language.Addon, Game.CreatureTextRange.Normal, 0, SoundKitPlayType.Normal, Team.Other, false, target);
}
}
}