From 64e596d92d00707abfbe5a2a3ecbee1c9641da3f Mon Sep 17 00:00:00 2001 From: Meta Vens Date: Sat, 13 Jun 2026 11:14:38 +0100 Subject: [PATCH] Demote Unity config MessagePack metadata --- .voidbot/state/aetheria.cc | Bin 25901 -> 26536 bytes .../Scripts/Editor/GameplaySettingsEditor.cs | 4 +- Assets/Scripts/ServerShared/EnumDictionary.cs | 6 +- Assets/Scripts/ServerShared/Environment.cs | 119 +++++++++--------- .../Scripts/ServerShared/ExponentialCurve.cs | 17 ++- Assets/Scripts/ServerShared/Settings.cs | 21 ++-- .../Scripts/ServerShared/WwiseSoundBinding.cs | 11 -- Assets/Scripts/UI/Menu/SectorMap.cs | 1 - Assets/Scripts/UnityExtensions.cs | 1 - docs/aetheria-perfect-machine-map.md | 10 +- 10 files changed, 84 insertions(+), 106 deletions(-) diff --git a/.voidbot/state/aetheria.cc b/.voidbot/state/aetheria.cc index 69e01a3561b41f63173b0feee52c083fe955d192..e38382177676a8e1122774c0abdd7673592f34a4 100644 GIT binary patch delta 1373 zcmZWpO>7%Q6t3NpG*yezD3uyP$fGKxQXT(9Y2pUd(mEDGt--2^su~GtcK6vkWOrsY zGwXDFsj8}X(A>E4D^w(qZwLv&ksg2}5f_diaX?%-@OEqm8BVMHc6R3bd-M7Cg-?Gd zeDQJdM6I^HzFEFpt#{umoU!dYGxkaG(FCnsa;Q9d&mmjo>g7#`96z>Pyd4i$kNGRF zuxn^SRGdM8u{0RKuHYsEUy2^@r-~UaMMbAcB9#F@Vp^jHnHrEikWpZNz4&~u{1JWN z@j>BY2aVyPugktJLGx}R1q#Di)JW9;N1zyRB}GiQd%wNUHFjhwg6mua^shsi2%ss_ zc!&Er0j9FDZ@=7LUU@Hs#4h9^R@dOqgV#1NHr;Fq1LRAZRYO*k8|Q0 z_E90QNJ~(pb3m(lO2+Uii!q5XMo=ONuCieX0Y3+!v^H$P);eCNaK@ajF^>l~S?< zCQ9a!kOq*-wr1fz>_`xFxHgLZ9}}z`8shXqjD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playSettingsEditor.cs b/Assets/Scripts/Editor/GameplaySettingsEditor.cs index 78111eec7..697bd4207 100644 --- a/Assets/Scripts/Editor/GameplaySettingsEditor.cs +++ b/Assets/Scripts/Editor/GameplaySettingsEditor.cs @@ -3,8 +3,6 @@ using System.Collections; using System.Collections.Generic; using System.IO; using System.Linq; -using MessagePack; -using MessagePack.Formatters; using UnityEditor; using UnityEngine; @@ -98,4 +96,4 @@ public class GameSettingsEditor : Editor serializedObject.ApplyModifiedProperties(); } -} \ No newline at end of file +} diff --git a/Assets/Scripts/ServerShared/EnumDictionary.cs b/Assets/Scripts/ServerShared/EnumDictionary.cs index cbeb2a695..0366d5275 100644 --- a/Assets/Scripts/ServerShared/EnumDictionary.cs +++ b/Assets/Scripts/ServerShared/EnumDictionary.cs @@ -1,9 +1,7 @@ using System; -using MessagePack; -[MessagePackObject] public class EnumDictionary where E : Enum { - [Key(0)] public T[] Values; + public T[] Values; public EnumDictionary() { @@ -11,4 +9,4 @@ public class EnumDictionary where E : Enum } public T this[E key] => Values[Convert.ToInt32(key)]; -} \ No newline at end of file +} diff --git a/Assets/Scripts/ServerShared/Environment.cs b/Assets/Scripts/ServerShared/Environment.cs index 4cc25b8ed..917e97272 100644 --- a/Assets/Scripts/ServerShared/Environment.cs +++ b/Assets/Scripts/ServerShared/Environment.cs @@ -1,84 +1,80 @@ using System; -using MessagePack; using Unity.Mathematics; using static Unity.Mathematics.math; using static Unity.Mathematics.noise; using float2 = Unity.Mathematics.float2; -[Serializable, MessagePackObject] +[Serializable] public class ZoneEnvironment { - [Key(0)] public NebulaSettings Nebula; - [Key(1)] public FlowSettings Flow; - [Key(2)] public NoiseSettings Noise; - [Key(3)] public AmbientLightingSettings Lighting; - [Key(4)] public GridSettings Grid; + public NebulaSettings Nebula; + public FlowSettings Flow; + public NoiseSettings Noise; + public AmbientLightingSettings Lighting; + public GridSettings Grid; } -[Serializable, MessagePackObject] +[Serializable] public class NebulaSettings { - [Key(0)] public float FillDensity; - [Key(1)] public float FillDistance; - [Key(2)] public float FillExponent; - [Key(12)] public float FillOffset; - [Key(3)] public float PatchDensity; - [Key(4)] public float FloorOffset; - [Key(5)] public float FloorBlend; - [Key(6)] public float PatchBlend; - [Key(7)] public float Luminance; - [Key(13)] public float Extinction; - //[Key(8)] public float TintExponent; - [Key(9)] public float TintLodExponent; - [Key(10)] public float SafetyDistance; + public float FillDensity; + public float FillDistance; + public float FillExponent; + public float FillOffset; + public float PatchDensity; + public float FloorOffset; + public float FloorBlend; + public float PatchBlend; + public float Luminance; + public float Extinction; + public float TintLodExponent; + public float SafetyDistance; } -[Serializable, MessagePackObject] +[Serializable] public class GridSettings { - [Key(0)] public bool Enabled; - [Key(1)] public float Offset; + public bool Enabled; + public float Offset; } -[Serializable, MessagePackObject] +[Serializable] public class AmbientLightingSettings { - [Key(0)] public float DynamicSkyBoost; - [Key(1)] public float DynamicLodHigh; - [Key(2)] public float DynamicLodLow; - [Key(3)] public float DynamicIntensity; + public float DynamicSkyBoost; + public float DynamicLodHigh; + public float DynamicLodLow; + public float DynamicIntensity; } -[Serializable, MessagePackObject] +[Serializable] public class FlowSettings { - [Key(0)] public float GlobalScale; - [Key(1)] public float GlobalAmplitude; - [Key(2)] public float GlobalScrollSpeed; - [Key(3)] public float Period; - [Key(4)] public float SlopeAmplitude; - [Key(5)] public float SwirlAmplitude; + public float GlobalScale; + public float GlobalAmplitude; + public float GlobalScrollSpeed; + public float Period; + public float SlopeAmplitude; + public float SwirlAmplitude; } -[Serializable, MessagePackObject] +[Serializable] public class NoiseSettings { - [Key(0)] public float Scale; - [Key(1)] public float Amplitude; - [Key(2)] public float Exponent; - [Key(3)] public float Speed; - [Key(4)] public float SlopeExponent; + public float Scale; + public float Amplitude; + public float Exponent; + public float Speed; + public float SlopeExponent; } -[Union(0, typeof(PowerBrush)), - Union(1, typeof(SimplexBrush)), - Serializable, MessagePackObject] +[Serializable] public abstract class Brush { - [Key(0)] public BrushLayer LayerMask; - [Key(1)] public float Cutoff; - [Key(2)] public float Depth; - [Key(3)] public float EnvelopeExponent; + public BrushLayer LayerMask; + public float Cutoff; + public float Depth; + public float EnvelopeExponent; float powerPulse( float x, float power ) { @@ -97,7 +93,7 @@ public abstract class Brush } } -[Serializable, MessagePackObject] +[Serializable] public class PowerBrush : Brush { protected override float Evaluate(float2 world, float2 uv) @@ -106,26 +102,25 @@ public class PowerBrush : Brush } } -[Serializable, MessagePackObject] +[Serializable] public abstract class TextureBrush : Brush { - [Key(4)] public float2 Frequency; - [Key(5)] public float2 Phase; + public float2 Frequency; + public float2 Phase; } -[Serializable, MessagePackObject] +[Serializable] public abstract class AnimatedBrush : TextureBrush { - [Key(6)] public float AnimationSpeed; + public float AnimationSpeed; - [IgnoreMember] public float Time { get; set; } } -[Serializable, MessagePackObject] +[Serializable] public class SimplexBrush : TextureBrush { - [Key(6)] public bool AbsoluteValue; + public bool AbsoluteValue; protected override float Evaluate(float2 world, float2 uv) { @@ -134,10 +129,10 @@ public class SimplexBrush : TextureBrush } } -[Serializable, MessagePackObject] +[Serializable] public class AnimatedSimplexBrush : AnimatedBrush { - [Key(7)] public bool AbsoluteValue; + public bool AbsoluteValue; protected override float Evaluate(float2 world, float2 uv) { @@ -146,10 +141,10 @@ public class AnimatedSimplexBrush : AnimatedBrush } } -[Serializable, MessagePackObject] +[Serializable] public class RadialWaveBrush : TextureBrush { - [Key(7)] public float WaveExponent; + public float WaveExponent; protected override float Evaluate(float2 world, float2 uv) { diff --git a/Assets/Scripts/ServerShared/ExponentialCurve.cs b/Assets/Scripts/ServerShared/ExponentialCurve.cs index 46f6506e1..a81b36490 100644 --- a/Assets/Scripts/ServerShared/ExponentialCurve.cs +++ b/Assets/Scripts/ServerShared/ExponentialCurve.cs @@ -5,35 +5,34 @@ using System; using System.Collections; using System.Collections.Generic; -using MessagePack; using Unity.Mathematics; using static Unity.Mathematics.math; -[Serializable, MessagePackObject] +[Serializable] public class ExponentialCurve { - [Key(0), Inspectable] + [Inspectable] public float Exponent; - [Key(1), Inspectable] + [Inspectable] public float Multiplier; - [Key(2), Inspectable] + [Inspectable] public float Constant; public float Evaluate(float value) => Multiplier * pow(value, Exponent) + Constant; } -[Serializable, MessagePackObject] +[Serializable] public class ExponentialLerp { - [Key(0), Inspectable] + [Inspectable] public float Exponent; - [Key(1), Inspectable] + [Inspectable] public float Minimum; - [Key(2), Inspectable] + [Inspectable] public float Maximum; public float Evaluate(float value) => Minimum + pow(saturate(value), Exponent) * (Maximum - Minimum); diff --git a/Assets/Scripts/ServerShared/Settings.cs b/Assets/Scripts/ServerShared/Settings.cs index 0d5d57f0d..b077efb80 100644 --- a/Assets/Scripts/ServerShared/Settings.cs +++ b/Assets/Scripts/ServerShared/Settings.cs @@ -5,12 +5,11 @@ using System; using System.Collections; using System.Collections.Generic; -using MessagePack; using Unity.Mathematics; using static Unity.Mathematics.math; using static Unity.Mathematics.noise; -[Serializable, MessagePackObject(keyAsPropertyName:true)] +[Serializable] public class PlanetSettings { public float ZoneDepthExponent; @@ -35,7 +34,7 @@ public class PlanetSettings public ExponentialCurve OrbitPeriod; } -[Serializable, MessagePackObject(keyAsPropertyName:true)] +[Serializable] public class GalaxyShapeSettings { public int Arms = 4; @@ -43,7 +42,7 @@ public class GalaxyShapeSettings public float TwistExponent = 2; } -[Serializable, MessagePackObject(keyAsPropertyName:true)] +[Serializable] public class NameGeneratorSettings { public int NameGeneratorMinLength = 5; @@ -51,7 +50,7 @@ public class NameGeneratorSettings public int NameGeneratorOrder = 4; } -[Serializable, MessagePackObject(keyAsPropertyName:true)] +[Serializable] public class SectorBackgroundSettings { public float NoiseAmplitude; @@ -85,7 +84,7 @@ public class SectorBackgroundSettings } } -[Serializable, MessagePackObject(keyAsPropertyName:true)] +[Serializable] public class SectorGenerationSettings { public float LinkDensity = .5f; @@ -94,7 +93,7 @@ public class SectorGenerationSettings public int BossCount; } -[Serializable, MessagePackObject(keyAsPropertyName:true)] +[Serializable] public class TutorialGenerationSettings { public string ProtagonistFaction; @@ -106,7 +105,7 @@ public class TutorialGenerationSettings public int ZoneCount = 32; } -[Serializable, MessagePackObject(keyAsPropertyName:true)] +[Serializable] public class ZoneGenerationSettings { public ExponentialCurve PlanetSafetyRadius; @@ -151,7 +150,7 @@ public class ZoneGenerationSettings public string[] NameData; } -[Serializable, MessagePackObject(keyAsPropertyName: true)] +[Serializable] public class GameplaySettings { public EntitySettings DefaultEntitySettings; @@ -213,11 +212,11 @@ public class GameplaySettings public float AgentFiringMinDot = .99f; } -[Serializable, MessagePackObject(keyAsPropertyName: true)] +[Serializable] public class RarityTier { public string Name; public float Quality; public float3 Color; public float Rarity; -} \ No newline at end of file +} diff --git a/Assets/Scripts/ServerShared/WwiseSoundBinding.cs b/Assets/Scripts/ServerShared/WwiseSoundBinding.cs index 5472fdafc..5c7403f44 100644 --- a/Assets/Scripts/ServerShared/WwiseSoundBinding.cs +++ b/Assets/Scripts/ServerShared/WwiseSoundBinding.cs @@ -1,20 +1,9 @@ -using MessagePack; -[MessagePackObject] public class WwiseSoundBinding { - [Key(0)] public uint PlayEvent; } -[MessagePackObject] public class WwiseLoopingSoundBinding : WwiseSoundBinding { - [Key(1)] public uint StopEvent; } - -// public class WwiseParameterBinding -// { -// [Key(0)] -// public uint Parameter; -// } \ No newline at end of file diff --git a/Assets/Scripts/UI/Menu/SectorMap.cs b/Assets/Scripts/UI/Menu/SectorMap.cs index fa4d220d0..98cbefb9a 100644 --- a/Assets/Scripts/UI/Menu/SectorMap.cs +++ b/Assets/Scripts/UI/Menu/SectorMap.cs @@ -3,7 +3,6 @@ using System.Collections; using System.Collections.Generic; using System.IO; using System.Linq; -using MessagePack; using TMPro; using UniRx; using UnityEngine; diff --git a/Assets/Scripts/UnityExtensions.cs b/Assets/Scripts/UnityExtensions.cs index febd4bf96..174e3d2c1 100644 --- a/Assets/Scripts/UnityExtensions.cs +++ b/Assets/Scripts/UnityExtensions.cs @@ -4,7 +4,6 @@ using System.Collections.Generic; using System.Linq; using System.Reflection; using System.Text.RegularExpressions; -using MessagePack; using Unity.Mathematics; using UnityEngine; using Random = UnityEngine.Random; diff --git a/docs/aetheria-perfect-machine-map.md b/docs/aetheria-perfect-machine-map.md index cc993dc7b..22ebf38f3 100644 --- a/docs/aetheria-perfect-machine-map.md +++ b/docs/aetheria-perfect-machine-map.md @@ -157,10 +157,12 @@ legacy catalog cache, and legacy UI paths should be migration-only or deleted. parse/display models, not MessagePack save shapes. `PlayerSettings` is a plain session-local runtime object until typed Verse settings are imported into Unity. `ZoneData` body/orbit DTOs, `ItemInstance` DTOs, - `EntitySettings`, and `Ship` are also plain runtime/session projections now, - not MessagePack persistence shapes. The global scene-load MessagePack - resolver hook is deleted. The slime compute settings path no longer - serializes its local parameter struct for change detection. + `EntitySettings`, `Ship`, Unity inspector game settings, environment/volume + settings, exponential curves, Wwise bindings, and enum dictionaries are also + plain runtime/session/config projections now, not MessagePack persistence + shapes. The global scene-load MessagePack resolver hook is deleted. The slime + compute settings path no longer serializes its local parameter struct for + change detection. - The dead story compiled-JSON cache sketch and its SHA helper are deleted; story compilation currently reads Ink source directly until a typed Verse story/cache document exists.