Move AetherDrive visuals behind runtime owner

This commit is contained in:
Meta Vens 2026-06-14 17:54:23 +01:00
commit d6e478cd5b
4 changed files with 8 additions and 4 deletions

Binary file not shown.

View file

@ -50,7 +50,7 @@ public class ShipInstance : EntityInstance
var drive = ship.GetBehavior<AetherDrive>();
if (drive != null)
{
var particles = Instantiate(UnityHelpers.LoadAsset<ParticleSystem>(drive.DriveData.Particles), transform, false);
var particles = Instantiate(UnityHelpers.LoadAsset<ParticleSystem>(drive.Particles), transform, false);
var main = particles.main;
main.customSimulationSpace = LocalSpace;
_aetherDrive = new AetherDriveInstance

View file

@ -67,8 +67,7 @@ public class AetherDrive : Behavior
public float3 Rpm { get; private set; }
public float MaximumRpm { get; private set; }
public float2 ThrustDirection { get; private set; }
public AetherDriveData DriveData => _data;
public string Particles { get; }
public float3 Axis
{
@ -79,11 +78,13 @@ public class AetherDrive : Behavior
public AetherDrive(AetherDriveData data, EquippedItem item) : base(data, item)
{
_data = data;
Particles = data.Particles;
}
public AetherDrive(AetherDriveData data, ConsumableItemEffect item) : base(data, item)
{
_data = data;
Particles = data.Particles;
}
public override bool Execute(float dt)
@ -141,4 +142,4 @@ public class AetherDrive : Behavior
return false;
}
}
}

View file

@ -1010,6 +1010,9 @@ First Aetheria surfaces to publish:
- 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: move AetherDrive particle prefab lookup off `AetherDriveData`;
`ShipInstance` now consumes `AetherDrive.Particles`, and the public
`DriveData` escape hatch has been removed.
- 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