mirror of
https://github.com/mangosfour/server.git
synced 2025-12-19 04:37:06 +00:00
[11951] Unify loot related code and fix engrish.
Also readd the m_groupLootId check in case the StopGroupLoot will be called from other places Signed-off-by: Schmoozerd <schmoozerd@scriptdev2.com>
This commit is contained in:
parent
1c5f99f4b8
commit
f153193a02
5 changed files with 16 additions and 15 deletions
|
|
@ -1820,13 +1820,14 @@ void GameObject::SetDisplayId(uint32 modelId)
|
|||
void GameObject::StartGroupLoot(Group* group, uint32 timer)
|
||||
{
|
||||
m_groupLootId = group->GetId();
|
||||
|
||||
if (m_groupLootId)
|
||||
m_groupLootTimer = timer;
|
||||
m_groupLootTimer = timer;
|
||||
}
|
||||
|
||||
void GameObject::StopGroupLoot()
|
||||
{
|
||||
if (!m_groupLootId)
|
||||
return;
|
||||
|
||||
if (Group* group = sObjectMgr.GetGroupById(m_groupLootId))
|
||||
group->EndRoll();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue