#[BUG] Entities 1.1.0-exp.1 2022.3.12f Building exception
1 messages · Page 1 of 1 (latest)
@low bay
Now something I noticed is that when I disable this code it builds fine (but game obviously can't function without referencing scenes).
public override void Bake(SceneDatabaseAuthoring databaseAuthoring)
{
var sceneDefinitions = AssetUtility.GetAssets<SceneDefinition>("Assets/Data/Scenes");
var sortedScenes = sceneDefinitions.OrderBy(x => x.SceneId);
var entity = GetEntity(TransformUsageFlags.None);
var buffer = AddBuffer<SceneReferenceBufferData>(entity);
foreach (var sceneDefinition in sortedScenes)
{
buffer.Add(new SceneReferenceBufferData()
{
Value = new EntitySceneReference(sceneDefinition.subScene.SceneAsset)
});
}
}
if relevant: AssetUtility.GetAssets is calling AssetDatabase.FindAssets, but exactly same error happens if I author directly via authoring field.
Something I found during debugging in ContentArchivesBuildUtility.cs line 68
Basically it adds tons of duplicate AssetBundleBuilds
f0d5b4df98c9d2c4a9cade8503336081 is a scene asset. Pretty big one.
Is this scene also being reference by a scene from the build window?
no
I build via script, where I specify just one game object scene, which is not in that list at all