diff --git a/.voidbot/state/aetheria.cc b/.voidbot/state/aetheria.cc index a94aeba66..29ba6444a 100644 Binary files a/.voidbot/state/aetheria.cc and b/.voidbot/state/aetheria.cc differ diff --git a/Assets/Scripts/Gameplay/ShipInstance.cs b/Assets/Scripts/Gameplay/ShipInstance.cs index 34e408dfd..56c42425c 100644 --- a/Assets/Scripts/Gameplay/ShipInstance.cs +++ b/Assets/Scripts/Gameplay/ShipInstance.cs @@ -63,8 +63,7 @@ public class ShipInstance : EntityInstance } _thrusters = ship.GetBehaviors().Select(thruster => { - var effectData = (ThrusterData) thruster.Data; - var particles = Instantiate(UnityHelpers.LoadAsset(effectData.ParticlesPrefab), transform, false); + var particles = Instantiate(UnityHelpers.LoadAsset(thruster.ParticlesPrefab), transform, false); var particlesShape = particles.shape; var thrusterHardpoint = ThrusterHardpoints .FirstOrDefault(t => t.name == ship.Hardpoints[thruster.Item.Position.x, thruster.Item.Position.y].Transform); diff --git a/Assets/Scripts/ServerShared/Behaviors/Thruster.cs b/Assets/Scripts/ServerShared/Behaviors/Thruster.cs index 7e5da7f8e..06c009b3a 100644 --- a/Assets/Scripts/ServerShared/Behaviors/Thruster.cs +++ b/Assets/Scripts/ServerShared/Behaviors/Thruster.cs @@ -38,6 +38,7 @@ public class Thruster : Behavior, IAnalogBehavior { public float Thrust { get; private set; } public float Torque { get; } + public string ParticlesPrefab { get; } public float Axis { @@ -52,6 +53,7 @@ public class Thruster : Behavior, IAnalogBehavior public Thruster(ThrusterData data, EquippedItem item) : base(data, item) { _data = data; + ParticlesPrefab = data.ParticlesPrefab; var hullShape = ItemManager.GetRuntimeShape(Entity.Hull); var itemShape = ItemManager.GetRuntimeShape(item.EquippableItem); var hullCenter = hullShape.CenterOfMass; @@ -64,6 +66,7 @@ public class Thruster : Behavior, IAnalogBehavior public Thruster(ThrusterData data, ConsumableItemEffect item) : base(data, item) { _data = data; + ParticlesPrefab = data.ParticlesPrefab; Torque = 0; Thrust = Evaluate(_data.Thrust); } diff --git a/docs/aetheria-perfect-machine-map.md b/docs/aetheria-perfect-machine-map.md index a1e05f140..b92094452 100644 --- a/docs/aetheria-perfect-machine-map.md +++ b/docs/aetheria-perfect-machine-map.md @@ -1007,6 +1007,9 @@ First Aetheria surfaces to publish: off `InstantWeaponData`/`ConstantWeaponData`; `EntityInstance` caches managers by `Weapon.EffectPrefab`, and constant effect managers consume live `ConstantWeapon` stats. + - Done: move thruster particle prefab lookup off `ThrusterData`; + `ShipInstance` now consumes `Thruster.ParticlesPrefab`, so the renderer + reads live behavior metadata instead of the temporary config bridge. - Done: delete the legacy `Behaviors` lists from `ConsumableItemData` and `EquippableItemData`; item DTOs can no longer carry behavior config state. - Done: move runtime blueprint price aggregation and conductivity restore