Core: Updated to 10.0.2
Port From (https://github.com/TrinityCore/TrinityCore/commit/e98e1283ea0034baf6be9aa2ffb386eb5582801b)
This commit is contained in:
@@ -67,6 +67,29 @@ namespace Game.Entities
|
||||
T GetValue();
|
||||
}
|
||||
|
||||
public class UpdateFieldString : IUpdateField<string>
|
||||
{
|
||||
public string _value;
|
||||
public int BlockBit;
|
||||
public int Bit;
|
||||
|
||||
public UpdateFieldString(int blockBit, int bit)
|
||||
{
|
||||
BlockBit = blockBit;
|
||||
Bit = bit;
|
||||
_value = "";
|
||||
}
|
||||
|
||||
public static implicit operator string(UpdateFieldString updateField)
|
||||
{
|
||||
return updateField._value;
|
||||
}
|
||||
|
||||
public void SetValue(string value) { _value = value; }
|
||||
|
||||
public string GetValue() { return _value; }
|
||||
}
|
||||
|
||||
public class UpdateField<T> : IUpdateField<T> where T : new()
|
||||
{
|
||||
public T _value;
|
||||
@@ -380,6 +403,8 @@ namespace Game.Entities
|
||||
((IHasChangesMask)updateField._value).ClearChangesMask();
|
||||
}
|
||||
|
||||
public void ClearChangesMask(UpdateFieldString updateField) { }
|
||||
|
||||
public void ClearChangesMask<U>(OptionalUpdateField<U> updateField) where U : new()
|
||||
{
|
||||
if (typeof(IHasChangesMask).IsAssignableFrom(typeof(U)) && updateField.HasValue())
|
||||
|
||||
Reference in New Issue
Block a user