fix: Adds generic entity persistence support and BOBEntry as entities (#1527)
### Summary
Adds a generic entity persistence. This can be used to create new entity types that have a `Serial`.
Here is an example:
```cs
public class BOBEntries : GenericEntitySerialization<IBOBEntry>
{
public static void Configure()
{
Configure("BOBEntries");
}
}
```
The annotation tells the system what folder to serialize the entries to. The class/interface (`IBOBEntry`) is the root type that implements `ISerializable`.
This commit is contained in:
parent
666b83a3dd
commit
e0225c6e59
22 changed files with 666 additions and 311 deletions
16
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BOBLargeEntry.v1.json
generated
Normal file
16
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BOBLargeEntry.v1.json
generated
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
"version": 1,
|
||||
"type": "Server.Engines.BulkOrders.BOBLargeEntry",
|
||||
"properties": [
|
||||
{
|
||||
"name": "Entries",
|
||||
"type": "Server.Engines.BulkOrders.BOBLargeSubEntry[]",
|
||||
"rule": "ArrayMigrationRule",
|
||||
"ruleArguments": [
|
||||
"Server.Engines.BulkOrders.BOBLargeSubEntry",
|
||||
"RawSerializableMigrationRule",
|
||||
""
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
35
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BOBLargeSubEntry.v0.json
generated
Normal file
35
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BOBLargeSubEntry.v0.json
generated
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
{
|
||||
"version": 0,
|
||||
"type": "Server.Engines.BulkOrders.BOBLargeSubEntry",
|
||||
"properties": [
|
||||
{
|
||||
"name": "ItemType",
|
||||
"type": "System.Type",
|
||||
"rule": "PrimitiveTypeMigrationRule"
|
||||
},
|
||||
{
|
||||
"name": "AmountCur",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
"EncodedInt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Number",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
"EncodedInt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Graphic",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
"EncodedInt"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
35
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BOBSmallEntry.v1.json
generated
Normal file
35
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BOBSmallEntry.v1.json
generated
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
{
|
||||
"version": 1,
|
||||
"type": "Server.Engines.BulkOrders.BOBSmallEntry",
|
||||
"properties": [
|
||||
{
|
||||
"name": "ItemType",
|
||||
"type": "System.Type",
|
||||
"rule": "PrimitiveTypeMigrationRule"
|
||||
},
|
||||
{
|
||||
"name": "AmountCur",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
"EncodedInt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Number",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
"EncodedInt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Graphic",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
"EncodedInt"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
40
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BaseBOBEntry.v1.json
generated
Normal file
40
Projects/UOContent/Migrations/Server.Engines.BulkOrders.BaseBOBEntry.v1.json
generated
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
{
|
||||
"version": 1,
|
||||
"type": "Server.Engines.BulkOrders.BaseBOBEntry",
|
||||
"properties": [
|
||||
{
|
||||
"name": "RequireExceptional",
|
||||
"type": "bool",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
""
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "DeedType",
|
||||
"type": "Server.Engines.BulkOrders.BODType",
|
||||
"rule": "EnumMigrationRule"
|
||||
},
|
||||
{
|
||||
"name": "Material",
|
||||
"type": "Server.Engines.BulkOrders.BulkMaterialType",
|
||||
"rule": "EnumMigrationRule"
|
||||
},
|
||||
{
|
||||
"name": "AmountMax",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
""
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Price",
|
||||
"type": "int",
|
||||
"rule": "PrimitiveTypeMigrationRule",
|
||||
"ruleArguments": [
|
||||
""
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue