Core/Unit: Implement more helper methods
Port From (https://github.com/TrinityCore/TrinityCore/commit/104ec7a81a5bb782f81fd05b872bf664e4de1c89)
This commit is contained in:
@@ -1674,10 +1674,13 @@ namespace Game.Entities
|
||||
}
|
||||
|
||||
//Unit
|
||||
public void SetLevel(uint lvl)
|
||||
public void SetLevel(uint lvl, bool sendUpdate = true)
|
||||
{
|
||||
SetUpdateFieldValue(m_values.ModifyValue(m_unitData).ModifyValue(m_unitData.Level), lvl);
|
||||
|
||||
if (!sendUpdate)
|
||||
return;
|
||||
|
||||
Player player = ToPlayer();
|
||||
if (player != null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user