Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changes in Fbx Exporter

## [Unreleased]
### Changed
- Replaced obsolete `EntityId.GetRawData()` with `EntityId.ToULong(EntityId)` (warning CS0618).
- Replaced obsolete `SearchService.GetItems` with `SearchService.Request`(warning CS0618).

## [5.1.5] - 2025-09-24
### Changed
- Updated the APIs used around EntityId
Expand Down
8 changes: 6 additions & 2 deletions com.unity.formats.fbx/Editor/ConvertToNestedPrefab.cs
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ internal static void FixSceneReferenceToObject(Object sceneObj, GameObject toCon
internal static List<Object> GetSceneReferences(Object obj)
{
#if UNITY_6000_4_OR_NEWER
var instanceId = obj.GetEntityId().GetRawData();
var instanceId = EntityId.ToULong(obj.GetEntityId());
Comment thread
mfe marked this conversation as resolved.
#else
var instanceId = obj.GetInstanceID();
#endif
Expand All @@ -283,8 +283,12 @@ internal static List<Object> GetSceneReferences(Object obj)
using (var searchContext = UnityEditor.Search.SearchService.CreateContext(query))
{
// Initiate the query and get the first results.
#if UNITY_6000_5_OR_NEWER
var items = UnityEditor.Search.SearchService.Request(searchContext, SearchFlags.Synchronous);
#else
var items = UnityEditor.Search.SearchService.GetItems(searchContext, SearchFlags.Synchronous);
return items.ConvertAll(x => x.ToObject());
#endif
Comment thread
mfe marked this conversation as resolved.
return items.Where(x => x != null).Select(x => x.ToObject()).ToList();
}
}

Expand Down