Fixed DB2 loading and world login!!!!!

This commit is contained in:
hondacrx
2018-12-14 18:43:35 -05:00
parent 8e20114e10
commit f414068883
44 changed files with 779 additions and 852 deletions
@@ -82,13 +82,14 @@ namespace Game.Entities
public void EncodeDynamicFieldChangeType(DynamicFieldChangeType changeType, UpdateType updateType)
{
_updateType = updateType;
DynamicFieldChangeType = (uint)(_blockCount | ((uint)(changeType & Entities.DynamicFieldChangeType.ValueAndSizeChanged) * ((3 - (int)updateType /*this part evaluates to 0 if update type is not VALUES*/) / 3)));
}
public override void AppendToPacket(ByteBuffer data)
{
data.WriteUInt16(DynamicFieldChangeType);
if (DynamicFieldChangeType.HasAnyFlag((uint)Entities.DynamicFieldChangeType.ValueAndSizeChanged))
if (DynamicFieldChangeType.HasAnyFlag((uint)Entities.DynamicFieldChangeType.ValueAndSizeChanged) && _updateType == UpdateType.Values)
data.WriteUInt32(_fieldCount);
var maskArray = new byte[_blockCount << 2];
@@ -98,6 +99,7 @@ namespace Game.Entities
}
public uint DynamicFieldChangeType;
public UpdateType _updateType;
}
public enum DynamicFieldChangeType
+2 -2
View File
@@ -155,8 +155,8 @@ namespace Game.Entities
{
flags.ThisIsYou = true;
flags.ActivePlayer = true;
tempObjectType = TypeId.Player;
tempObjectTypeMask |= TypeMask.Player;
tempObjectType = TypeId.ActivePlayer;
tempObjectTypeMask |= TypeMask.ActivePlayer;
}
switch (GetGUID().GetHigh())