//public List<string> TextToAdd = new List<string>(); public _0xD6MegaCliloc(UOStream Data) : base(Data) { length = Data.ReadShort(); unknown1 = Data.ReadShort(); if (unknown1 != 0x0001) { this.Data.Position -= 2; for (int i = 0; i < length - 3 / 4; i++) RequestedItems.Add(Data.ReadInt()); return; } Serial = Data.ReadInt(); unknown2 = Data.ReadShort(); OwnerID = Data.ReadInt(); List<string> Cliocs = new List<string>(); while(Data.Position + 6 <= Data.Length) { int MessageNumber = Data.ReadInt(); short textlen = Data.ReadShort(); if(textlen > 0) { string _args = Data.ReadString(textlen); Cliocs.Add(Helpers.Cliloc.constructCliLoc(Helpers.Cliloc.Table[MessageNumber].ToString(), _args)); } Cliocs.Add(Helpers.Cliloc.Table[MessageNumber].ToString()); } Data.Position += 4; //TODO FINISH THIS }
public _0x78DrawObject(UOStream Data) : base(Data) { this.Data = Data; this.Serial = Data.ReadInt(); this.GraphicID = Data.ReadShort(); this.X = Data.ReadShort(); this.Y = Data.ReadShort(); this.Z = Data.ReadBit(); this.Direction = Data.ReadBit(); this.Hue = Data.ReadShort(); this.Flags = Data.ReadBit(); this.Notoriety = Data.ReadBit(); int serial; while ((serial = Data.ReadInt()) != 0) { short graphicID = Data.ReadShort(); byte layer = Data.ReadBit(); if ((graphicID & 0x8000) == graphicID) { short hue = Data.ReadShort(); } } }
public _0xDEUpdateMobileStatus(UOStream Data) : base(Data) { _len = Data.ReadShort(); Serial = Data.ReadInt(); Status = Data.ReadBit(); if (Status == 1) AttackerSerial = Data.ReadInt(); }
public _0x08DropItem(UOStream data) : base(data) { this.Serial = data.ReadInt(); this.X = data.ReadShort(); this.Y = data.ReadShort(); this.Z = data.ReadBit(); this.GridIndex = data.ReadBit(); this.ContainerSerial = data.ReadInt(); }
public _0x2EWornItem(UOStream Data) : base(Data) { Serial = Data.ReadInt(); GraphicID = Data.ReadShort(); unknown = Data.ReadBit(); Layer = Data.ReadBit(); OwnerSerial = Data.ReadInt(); Hue = Data.ReadShort(); }
public _0xAEUnicodeSpeech(UOStream Data) : base(Data) { _length = Data.ReadShort(); Serial = Data.ReadInt(); GraphicID = Data.ReadShort(); type = Data.ReadBit(); hue = Data.ReadShort(); font = Data.ReadShort(); Language = Data.ReadInt(); SpeakerName = Data.ReadString(30); Message = Data.ReadNullTermString(); }
byte OffSetGraphicID; // unknown?? #endregion Fields #region Constructors public _0x25AddItemToContainer(UOStream Data) : base(Data) { Serial = Data.ReadInt(); GraphicID = Data.ReadShort(); OffSetGraphicID = Data.ReadBit(); Amount = Data.ReadShort(); X = Data.ReadShort(); Y = Data.ReadShort(); Index = Data.ReadBit(); ContainerSerial = Data.ReadInt(); Hue = Data.ReadShort(); this.Item = new Item(this); }
public _0xC1ClilocMessage(UOStream Data) : base(Data) { _length = Data.ReadShort(); Serial = Data.ReadInt(); GraphicID = Data.ReadShort(); type = Data.ReadBit(); hue = Data.ReadShort(); font = Data.ReadShort(); MessageNumber = Data.ReadInt(); SpeakerName = Data.ReadString(30); _args = Data.ReadNullTermString(); Message = Helpers.Cliloc.constructCliLoc(Helpers.Cliloc.Table[MessageNumber].ToString(), _args); }
public _0xB0SendGumpMenuDialog(UOStream Data) : base(Data) { length = Data.ReadShort(); ID = Data.ReadInt(); GumpID = Data.ReadInt(); X = Data.ReadInt(); Y = Data.ReadInt(); commands = Data.ReadString(Data.ReadShort()); numTextLines = Data.ReadShort(); for (int i = 0; i <= numTextLines; i++) { Text.Add(Data.ReadString(Data.ReadShort())); } Logger.Log(this.ToString()); }
public _0x88OpenPaperDoll(UOStream Data) : base(Data) { this.Serial = Data.ReadInt(); this.Text = Data.ReadString(60); this.Flags = Data.ReadBit(); }
public _0xD6MegaCliloc(UOStream Data) : base(Data) { Helpers.Cliloc Clilocdata = new Helpers.Cliloc(); Helpers.Cliloc.LoadStringList("enu"); length = Data.ReadShort(); unknown1 = Data.ReadShort(); Serial = Data.ReadInt(); unknown2 = Data.ReadShort(); OwnerID = Data.ReadInt(); List<string> Cliocs = new List<string>(); while(Data.Position + 6 < Data.Length) { ClilocIDs.Add(Data.ReadInt()); TextToAdd.Add(Data.ReadString(Data.ReadShort())); Cliocs.Add(Helpers.Cliloc.Table[ClilocIDs.Last()].ToString()); } //TODO FINISH THIS }
public _0x3CAddMultipleItemsToContainer(UOStream Data) : base(Data) { _length = Data.ReadShort(); _numberOfItems = Data.ReadShort(); while (Data.Position + 4 < Data.Length) { int Serial = Data.ReadInt(); short GraphicID = Data.ReadShort(); byte OffSetGraphicID = Data.ReadBit(); // Could be unknown short Amount = Data.ReadShort(); short X = Data.ReadShort(); short Y = Data.ReadShort(); byte Index = Data.ReadBit(); int ContainerSerial = Data.ReadInt(); short Hue = Data.ReadShort(); Items.Add(new Item(Serial,GraphicID,Amount,X,Y,Index,ContainerSerial,Hue)); } }
public _0x1BCharLocaleBody(UOStream Data) : base(Data) { ID = Data.ReadInt(); i1 = Data.ReadInt(); GraphicID = Data.ReadShort(); X = Data.ReadShort(); Y = Data.ReadShort(); Unknown1 = Data.ReadBit(); Z = Data.ReadBit(); Facing = Data.ReadBit(); i2 = Data.ReadInt(); i3 = Data.ReadInt(); Unknown2 = Data.ReadBit(); ServerBoundX = Data.ReadShort(); ServerBoundY = Data.ReadShort(); Unknown3 = Data.ReadShort(); i4 = Data.ReadInt(); }
public _0x2DMobAttributes(UOStream Data) : base(Data) { ID = Data.ReadInt(); HitsMax = Data.ReadShort(); HitsCurrent = Data.ReadShort(); ManaMax = Data.ReadShort(); ManaCurrent = Data.ReadShort(); StamMax = Data.ReadShort(); StamCurrent = Data.ReadShort(); }
public _0x16StatusBarUpdate(UOStream Data) : base(Data) { length = Data.ReadShort(); ID = Data.ReadInt(); Extended = Data.ReadShort(); if (Extended != 0x0000) { HealthBarColor = Data.ReadShort(); Flag = Data.ReadBit(); } }
public _0x1CSendSpeech(UOStream Data) : base(Data) { length = Data.ReadShort(); ObjectID = Data.ReadInt(); GraphicID = Data.ReadShort(); TypeOfText = Data.ReadBit(); TextColor = Data.ReadShort(); Font = Data.ReadShort(); Name = Data.ReadString(30); // try normal read? Message = Data.ReadNullTermString(); }
public _0xA9CharStartingLocation(UOStream Data) : base(Data) { _length = Data.ReadShort(); NumberOfChars = Data.ReadBit(); for (int i = 0; i < NumberOfChars; i++) { Characters.Add((byte)(i+1),Data.ReadString(30)); } NumberStartingCities = Data.ReadBit(); for (int i = 0; i < NumberStartingCities; i++) { byte Index = Data.ReadBit(); string CityName = Data.ReadString(32); string AreaName = Data.ReadString(32); int X = Data.ReadInt(); int Y = Data.ReadInt(); int Z = Data.ReadInt(); int MapID = Data.ReadInt(); int cliloc = Data.ReadInt(); int zero = Data.ReadInt(); } if (Data.Position < _length) { Data.Position = _length; } }
public _0xB1GumpMenuSelection(UOStream Data) : base(Data) { length = Data.ReadShort(); GumpID = Data.ReadInt(); GumpType = Data.ReadInt(); ButtonID = Data.ReadInt(); SwitchCount = Data.ReadInt(); if (SwitchCount > 0) { for (int i = 0; i <= SwitchCount; i++) { SwitchID.Add(Data.ReadInt()); } } TextCount = Data.ReadInt(); if (TextCount > 0) { for (int i = 0; i <= TextCount; i++) { TextID.Add(Data.ReadShort()); TextLength.Add(Data.ReadShort()); UnicodeText.Add(Data.ReadString(TextLength[i] * 2)); } } }
public _0x20DrawGamePlayer(UOStream Data) : base(Data) { Serial = Data.ReadInt(); GraphicID = Data.ReadShort(); unknown1 = Data.ReadBit(); Hue = Data.ReadShort(); Flag = Data.ReadBit(); X = Data.ReadShort(); Y = Data.ReadShort(); Unknown2 = Data.ReadShort(); Direction = Data.ReadBit(); Z = Data.ReadBit(); }
public _0x77UpdatePlayer(UOStream Data) : base(Data) { this.Data = Data; this.PlayerID = Data.ReadInt(); this.GraphicID = Data.ReadShort(); this.X = Data.ReadShort(); this.Y = Data.ReadShort(); this.Z = Data.ReadBit(); this.Direction = Data.ReadBit(); this.Hue = Data.ReadShort(); this.Flags = Data.ReadBit(); this.HighliteColor = Data.ReadBit(); }
public _0xA8GameServerList(UOStream Data) : base(Data) { _length = Data.ReadShort(); Flag = Data.ReadBit(); NumServers = Data.ReadShort(); if(NumServers > 0) for (int i = 0; i < NumServers; i++) { Servers.Add(Data.ReadShort(), Data.ReadString(32)); Data.ReadBit();//percentfull Data.ReadBit(); // TimeZone Data.ReadInt();// IP } }
public _0xBFGeneralInfo(UOStream Data) : base(Data) { _length = Data.ReadShort(); SubCommand = Data.ReadShort(); switch (SubCommand) { case 4: int gumpID = Data.ReadInt(); int buttonID = Data.ReadInt(); break; case 0x22: Data.ReadShort();// Unknown short; int Serial = Data.ReadInt(); byte Damage = Data.ReadBit(); break; case 0x24: byte unknown = Data.ReadBit();// Unknown break; default: Logger.Log("Unhandled 0xBF: " + SubCommand); break; } }
public _0xF3ObjectInfo(UOStream Data) : base(Data) { unknown = Data.ReadShort(); DataType = Data.ReadBit(); Serial = Data.ReadInt(); GraphicID = Data.ReadShort(); Direction = Data.ReadBit(); Amount = Data.ReadShort(); Amount2 = Data.ReadShort(); X = Data.ReadShort(); Y = Data.ReadShort(); Z = Data.ReadBit(); Layer = Data.ReadBit(); Hue = Data.ReadShort(); Flag = Data.ReadBit(); }
public _0x8CConnectToGameServer(UOStream Data) : base(Data) { _ip[0] = Data.ReadBit(); _ip[1] = Data.ReadBit(); _ip[2] = Data.ReadBit(); _ip[3] = Data.ReadBit(); Port = Data.ReadShort(); Key = Data.ReadInt(); if (UOProxy.ProxyMode) { // If we are in proxy mode, overwrite servers IP with local IP IP = IPAddress.Loopback; Data.Position = 1; Data.Write(_ip, 0, 4); //ToDo Add Port override } }
public _0x11StatusBarInfo(UOStream Data) : base(Data) { Length = Data.ReadShort(); PlayerID = Data.ReadInt(); PlayerName = Data.Read30CharString(); HitsCurrent = Data.ReadShort(); NameChangeFlag = Data.ReadBit(); StatusFlag = Data.ReadBit(); SexRace = Data.ReadBit(); Str = Data.ReadShort(); Dex = Data.ReadShort(); Int = Data.ReadShort(); StamCurrent = Data.ReadShort(); StamMax = Data.ReadShort(); ManaCurrent = Data.ReadShort(); ManaMax = Data.ReadShort(); Gold = Data.ReadInt(); AR = Data.ReadShort(); Weight = Data.ReadShort(); if (StatusFlag >= 0x5) { MaxWeight = Data.ReadShort(); Race = Data.ReadBit(); } if (StatusFlag >= 0x3) { StatCap = Data.ReadShort(); Followers = Data.ReadBit(); FollowersMax = Data.ReadBit(); } if (StatusFlag >= 0x04) { FireRes = Data.ReadShort(); ColdRes = Data.ReadShort(); PoisonRes = Data.ReadShort(); EnergyRes = Data.ReadShort(); Luck = Data.ReadShort(); DmgMin = Data.ReadShort(); DmgMax = Data.ReadShort(); TithingPoints = Data.ReadInt(); } if (StatusFlag >= 0x06) { HitChanceIncrease = Data.ReadShort(); SwingSpeedIncrease = Data.ReadShort(); DamageChanceIncrease = Data.ReadShort(); LowerReagCost = Data.ReadShort(); HitsRegen = Data.ReadShort(); StamRegen = Data.ReadShort(); ManaRegen = Data.ReadShort(); ReflectPhys = Data.ReadShort(); EnhancePotions = Data.ReadShort(); DefenseChanceIncrease = Data.ReadShort(); SpellDamageIncrease = Data.ReadShort(); FasterCastRecovery = Data.ReadShort(); FasterCasting = Data.ReadShort(); LowerManaCost = Data.ReadShort(); StrIncrease = Data.ReadShort(); DexIncrease = Data.ReadShort(); IntIncrease = Data.ReadShort(); HitsIncrease = Data.ReadShort(); StamIncrease = Data.ReadShort(); ManaIncrease = Data.ReadShort(); MaxHitsIncrease = Data.ReadShort(); MaxStamIncrease = Data.ReadShort(); MaxManaIncrease = Data.ReadShort(); } }
public _0x05RequestAttack(UOStream data) : base(data) { this.ID = data.ReadInt(); }
public _0xDDCompressedGump(UOStream Data) : base(Data) { try { length_ = Data.ReadShort(); GumpID = Data.ReadInt(); GumpType = Data.ReadInt(); X = Data.ReadInt(); Y = Data.ReadInt(); compressedGumpLength = Data.ReadInt() - 4; decompressedGumpLength = Data.ReadInt(); if (compressedGumpLength > 1) { byte[] compressedGumpData = new byte[compressedGumpLength]; Data.Read(compressedGumpData, 0, compressedGumpLength); byte[] decompressedData = new byte[decompressedGumpLength]; OpenUO.Core.IO.ZlibCompression.Unpack(decompressedData, ref decompressedGumpLength, compressedGumpData, compressedGumpLength); string GumpData = Encoding.ASCII.GetString(decompressedData); int numTextLines = Data.ReadInt(); int compressedTextLength = Data.ReadInt() - 4; int decompressedTextLength = Data.ReadInt(); byte[] decompressedText = new byte[decompressedTextLength]; if (numTextLines > 0 && decompressedTextLength > 0) { byte[] compressedTextData = new byte[compressedTextLength]; Data.Read(compressedTextData, 0, compressedTextLength); OpenUO.Core.IO.ZlibCompression.Unpack(decompressedText, ref decompressedTextLength, compressedTextData, compressedTextLength); int index = 0; List<string> lines = new List<string>(); for (int i = 0; i < numTextLines; i++) { int length = decompressedText[index] * 256 + decompressedText[index + 1]; index += 2; byte[] b = new byte[length * 2]; Array.Copy(decompressedText, index, b, 0, length * 2); index += length * 2; lines.Add(Encoding.BigEndianUnicode.GetString(b)); } TextLines = lines.ToArray(); } else { TextLines = new string[0]; } } /*NumberTextLines = Data.ReadInt(); CompressedTextLen = Data.ReadInt() - 4; DecompressedTextLen = Data.ReadInt(); if (CompressedTextLen > 0) { GumpTextData = new byte[CompressedTextLen]; Data.Read(GumpTextData, 0, CompressedTextLen); } */ //byte[] UncompressedGumpData = new byte[decompressedGumpLength]; //OpenUO.Core.IO.ZlibCompression.Unpack(UncompressedGumpData,ref decompressedGumpLength,GumpData,compressedGumpLength); /*System.IO.MemoryStream outstream = new System.IO.MemoryStream(); zlib.ZOutputStream outZstream = new zlib.ZOutputStream(outstream); System.IO.MemoryStream input = new System.IO.MemoryStream(GumpData); CopyStream(input, outZstream); outZstream.finish(); outZstream.end(); byte[] UncompressedGumpData = new byte[outZstream.TotalOut]; outZstream.Position = 0; outZstream.Read(UncompressedGumpData, 0, (int)outZstream.TotalOut); */ //byte[] UncompressedGumpText = new byte[DecompressedTextLen]; //OpenUO.Core.IO.ZlibCompression.Unpack(UncompressedGumpText,ref DecompressedTextLen,GumpTextData,DecompressedTextLen); } catch (Exception e) { Logger.Log(e.ToString()); } }
public _0x0BDamage(UOStream Data) : base(Data) { Serial = Data.ReadInt(); DamageDealt = Data.ReadShort(); }
public _0x07PickUpItem(UOStream data) : base(data) { this.ID = data.ReadInt(); this.StackSize = data.ReadShort(); }
public _0x24DrawContainer(UOStream Data) : base(Data) { ID = Data.ReadInt(); GraphicID = Data.ReadShort(); }