fix: Moves containers/bods/traps/etc to serialization generator (#2310)
This commit is contained in:
parent
f4a87a8629
commit
c14f361de1
36 changed files with 950 additions and 1199 deletions
|
|
@ -1,9 +1,11 @@
|
|||
using ModernUO.Serialization;
|
||||
using Server.Accounting;
|
||||
using Server.Network;
|
||||
|
||||
namespace Server.Items;
|
||||
|
||||
public class SecureTradeContainer : Container
|
||||
[SerializationGenerator(0, false)]
|
||||
public partial class SecureTradeContainer : Container
|
||||
{
|
||||
public SecureTradeContainer(SecureTrade trade) : base(0x1E5E)
|
||||
{
|
||||
|
|
@ -12,10 +14,6 @@ public class SecureTradeContainer : Container
|
|||
Movable = false;
|
||||
}
|
||||
|
||||
public SecureTradeContainer(Serial serial) : base(serial)
|
||||
{
|
||||
}
|
||||
|
||||
public SecureTrade Trade { get; }
|
||||
|
||||
public override bool CheckHold(Mobile m, Item item, bool message, bool checkItems, int plusItems, int plusWeight)
|
||||
|
|
@ -95,18 +93,4 @@ public class SecureTradeContainer : Container
|
|||
child is VirtualCheck
|
||||
? AccountGold.Enabled && m.NetState is not { NewSecureTrading: true }
|
||||
: base.IsChildVisibleTo(m, child);
|
||||
|
||||
public override void Serialize(IGenericWriter writer)
|
||||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(IGenericReader reader)
|
||||
{
|
||||
base.Deserialize(reader);
|
||||
|
||||
var version = reader.ReadInt();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue