Demote non-item MessagePack DTOs
This commit is contained in:
parent
d2c062c94d
commit
98d58cac92
8 changed files with 48 additions and 51 deletions
|
|
@ -5,71 +5,69 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using MessagePack;
|
||||
using Unity.Mathematics;
|
||||
|
||||
[LegacyCatalogGroup("Galaxy"), Inspectable, MessagePackObject]
|
||||
[LegacyCatalogGroup("Galaxy"), Inspectable]
|
||||
public class Faction : DatabaseEntry, INamedEntry
|
||||
{
|
||||
[Inspectable, Key(1)]
|
||||
[Inspectable]
|
||||
public string Name;
|
||||
|
||||
[Inspectable, Key(2)]
|
||||
[Inspectable]
|
||||
public string ShortName;
|
||||
|
||||
[InspectableText, Key(3)]
|
||||
[InspectableText]
|
||||
public string Description;
|
||||
|
||||
[InspectableTexture, Key(4)]
|
||||
[InspectableTexture]
|
||||
public string Logo;
|
||||
|
||||
[InspectableDatabaseLink(typeof(PersonalityAttribute)), Key(5)]
|
||||
[InspectableDatabaseLink(typeof(PersonalityAttribute))]
|
||||
public Dictionary<Guid, float> Personality = new Dictionary<Guid, float>();
|
||||
|
||||
// [Inspectable, Key(6)]
|
||||
// [Inspectable]
|
||||
// public bool PlayerHostile;
|
||||
|
||||
[InspectableColor, Key(7)]
|
||||
[InspectableColor]
|
||||
public float3 PrimaryColor;
|
||||
|
||||
[InspectableColor, Key(8)]
|
||||
[InspectableColor]
|
||||
public float3 SecondaryColor;
|
||||
|
||||
[InspectableDatabaseLink(typeof(NameFile)), Key(9)]
|
||||
[InspectableDatabaseLink(typeof(NameFile))]
|
||||
public Guid GeonameFile;
|
||||
|
||||
[InspectableDatabaseLink(typeof(HullData)), Key(10)]
|
||||
[InspectableDatabaseLink(typeof(HullData))]
|
||||
public Guid BossHull;
|
||||
|
||||
[Inspectable, Key(11)]
|
||||
[Inspectable]
|
||||
public int InfluenceDistance = 4;
|
||||
|
||||
[InspectableDatabaseLink(typeof(Faction)), RangedFloat(0, 1), Key(12)]
|
||||
[InspectableDatabaseLink(typeof(Faction)), RangedFloat(0, 1)]
|
||||
public Dictionary<Guid, float> Allegiance = new Dictionary<Guid, float>();
|
||||
|
||||
[InspectableSoundBank, Key(13)]
|
||||
[InspectableSoundBank]
|
||||
public uint OverworldMusic;
|
||||
|
||||
[InspectableSoundBank, Key(14)]
|
||||
[InspectableSoundBank]
|
||||
public uint CombatMusic;
|
||||
|
||||
[InspectableSoundBank, Key(15)]
|
||||
[InspectableSoundBank]
|
||||
public uint BossMusic;
|
||||
|
||||
[IgnoreMember] public string EntryName
|
||||
{
|
||||
get => Name;
|
||||
set => Name = value;
|
||||
}
|
||||
}
|
||||
|
||||
[Inspectable, MessagePackObject]
|
||||
public class NameFile : DatabaseEntry, INamedEntry
|
||||
{
|
||||
[Key(1)] public string Name;
|
||||
[Key(2)] public string[] Names;
|
||||
|
||||
[IgnoreMember]
|
||||
public string EntryName
|
||||
{
|
||||
get => Name;
|
||||
set => Name = value;
|
||||
}
|
||||
}
|
||||
|
||||
[Inspectable]
|
||||
public class NameFile : DatabaseEntry, INamedEntry
|
||||
{
|
||||
public string Name;
|
||||
public string[] Names;
|
||||
|
||||
public string EntryName
|
||||
{
|
||||
get => Name;
|
||||
|
|
|
|||
|
|
@ -5,55 +5,54 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using MessagePack;
|
||||
using Unity.Mathematics;
|
||||
using static Unity.Mathematics.math;
|
||||
using static Unity.Mathematics.noise;
|
||||
using static NoiseFbm;
|
||||
|
||||
[Inspectable, Serializable, LegacyCatalogGroup("Galaxy"), MessagePackObject]
|
||||
[Inspectable, Serializable, LegacyCatalogGroup("Galaxy")]
|
||||
public class GalaxyMapLayerData : DatabaseEntry, INamedEntry
|
||||
{
|
||||
[Inspectable, Key(1)]
|
||||
[Inspectable]
|
||||
public float CoreBoost = 1.05f;
|
||||
|
||||
[Inspectable, Key(2)]
|
||||
[Inspectable]
|
||||
public float CoreBoostOffset = .1f;
|
||||
|
||||
[Inspectable, Key(3)]
|
||||
[Inspectable]
|
||||
public float CoreBoostPower = 2.25f;
|
||||
|
||||
[Inspectable, Key(4)]
|
||||
[Inspectable]
|
||||
public float SpokeScale = 1;
|
||||
|
||||
[Inspectable, Key(5)]
|
||||
[Inspectable]
|
||||
public float SpokeOffset = 0;
|
||||
|
||||
[Inspectable, Key(6)]
|
||||
[Inspectable]
|
||||
public float EdgeReduction = 3;
|
||||
|
||||
[Inspectable, Key(7)]
|
||||
[Inspectable]
|
||||
public float NoiseOffset = 0;
|
||||
|
||||
[Inspectable, Key(8)]
|
||||
[Inspectable]
|
||||
public float NoiseAmplitude = 1.5f;
|
||||
|
||||
[Inspectable, Key(9)]
|
||||
[Inspectable]
|
||||
public float NoiseGain = .7f;
|
||||
|
||||
[Inspectable, Key(10)]
|
||||
[Inspectable]
|
||||
public float NoiseLacunarity = 2;
|
||||
|
||||
[Inspectable, Key(11)]
|
||||
[Inspectable]
|
||||
public int NoiseOctaves = 7;
|
||||
|
||||
[Inspectable, Key(12)]
|
||||
[Inspectable]
|
||||
public float NoiseFrequency = 1;
|
||||
|
||||
[Inspectable, Key(13)]
|
||||
[Inspectable]
|
||||
public float NoisePosition = 1337;
|
||||
|
||||
[Inspectable, Key(14)]
|
||||
[Inspectable]
|
||||
public string Name;
|
||||
|
||||
public float Evaluate(float2 uv, GalaxyShapeSettings settings)
|
||||
|
|
@ -71,7 +70,7 @@ public class GalaxyMapLayerData : DatabaseEntry, INamedEntry
|
|||
return gal;
|
||||
}
|
||||
|
||||
[IgnoreMember] public string EntryName
|
||||
public string EntryName
|
||||
{
|
||||
get => Name;
|
||||
set => Name = value;
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ using System.IO;
|
|||
using System.Linq;
|
||||
using Ink;
|
||||
using Ink.Parsed;
|
||||
using MessagePack;
|
||||
using Path = System.IO.Path;
|
||||
using Random = Unity.Mathematics.Random;
|
||||
using Story = Ink.Runtime.Story;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using MessagePack;
|
||||
using Random = Unity.Mathematics.Random;
|
||||
|
||||
public abstract class ZoneSelector
|
||||
|
|
@ -48,4 +47,4 @@ public class RandomSelector : ZoneSelector
|
|||
{
|
||||
return candidates[Random.NextInt(candidates.Count)];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,25 +3,21 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
using System;
|
||||
using MessagePack;
|
||||
[LegacyCatalogGroup("Users"), MessagePackObject]
|
||||
|
||||
[LegacyCatalogGroup("Users")]
|
||||
public class PlayerData : DatabaseEntry, INamedEntry
|
||||
{
|
||||
[Key(1)]
|
||||
public string Email;
|
||||
|
||||
[Key(2)]
|
||||
public string Password;
|
||||
|
||||
[Key(3)]
|
||||
public string Username;
|
||||
|
||||
[Key(4)]
|
||||
public Guid Corporation;
|
||||
|
||||
[IgnoreMember] public string EntryName
|
||||
public string EntryName
|
||||
{
|
||||
get => Username;
|
||||
set => Username = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ using System.Collections.Generic;
|
|||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using GameCult.Aetheria.State.Unity;
|
||||
using MessagePack;
|
||||
using UniRx;
|
||||
using Unity.Mathematics;
|
||||
using static Unity.Mathematics.math;
|
||||
|
|
|
|||
Loading…
Reference in a new issue