public override void Marshal(DataOutputStream dos) { base.Marshal(dos); if (dos != null) { try { this._damagedEntityID.Marshal(dos); dos.WriteUnsignedShort((ushort)this._padding1); dos.WriteUnsignedShort((ushort)this._padding2); dos.WriteUnsignedShort((ushort)this._damageDescriptionRecords.Count); for (int idx = 0; idx < this._damageDescriptionRecords.Count; idx++) { DirectedEnergyDamage aDirectedEnergyDamage = (DirectedEnergyDamage)this._damageDescriptionRecords[idx]; aDirectedEnergyDamage.Marshal(dos); } } catch (Exception e) { #if DEBUG Trace.WriteLine(e); Trace.Flush(); #endif this.OnException(e); } } }