public void Convert(Entity entity, EntityManager dstManager, GameObjectConversionSystem conversionSystem) { if (!conversionSystem.TryGetBuildConfigurationComponent <DotsRuntimeBuildProfile>(out var _)) { return; } Unity.Tiny.Rendering.MeshRenderer mr = dstManager.GetComponentData <Unity.Tiny.Rendering.MeshRenderer>(entity); }
public void Convert(Entity entity, EntityManager dstManager, GameObjectConversionSystem conversionSystem) { if (!conversionSystem.TryGetBuildSettingsComponent <DotsRuntimeBuildProfile>(out var _)) { return; } Unity.Tiny.Rendering.MeshRenderer mr = dstManager.GetComponentData <Unity.Tiny.Rendering.MeshRenderer>(entity); dstManager.AddComponent <DynamicMaterial>(mr.material); }
public void Convert(Entity entity, EntityManager dstManager, GameObjectConversionSystem conversionSystem) { MeshRenderer meshRenderer = dstManager.GetComponentData <MeshRenderer>(entity); dstManager.AddComponent <DynamicMaterial>(meshRenderer.material); }