fix!: rename removeEntity to removeAsset

This commit is contained in:
Nick Fisher
2024-12-23 14:38:29 +08:00
parent 584ace23b4
commit b6397b5f73
2 changed files with 4 additions and 4 deletions

View File

@@ -972,7 +972,7 @@ class ThermionViewerFFI extends ThermionViewer {
///
///
@override
Future removeEntity(covariant FFIAsset asset) async {
Future removeAsset(covariant FFIAsset asset) async {
await withVoidCallback((callback) => SceneManager_destroyAssetRenderThread(
_sceneManager!, asset.pointer, callback));
}
@@ -1346,7 +1346,7 @@ class ThermionViewerFFI extends ThermionViewer {
///
///
@override
Future removeEntityFromScene(ThermionEntity entity) async {
Future removeAssetFromScene(ThermionEntity entity) async {
if (SceneManager_removeFromScene(_sceneManager!, entity) != 1) {
throw Exception("Failed to remove entity from scene");
}

View File

@@ -380,7 +380,7 @@ abstract class ThermionViewer {
/// Removes/destroys the specified entity from the scene.
/// [entity] will no longer be a valid handle after this method is called; ensure you immediately discard all references once this method is complete.
///
Future removeEntity(ThermionAsset asset);
Future removeAsset(ThermionAsset asset);
///
/// Removes/destroys all renderable entities from the scene (including cameras).
@@ -629,7 +629,7 @@ abstract class ThermionViewer {
///
/// Removes a single [entity] from the scene.
///
Future removeEntityFromScene(ThermionEntity entity);
Future removeAssetFromScene(ThermionEntity entity);
///
/// Hit test the viewport at the given coordinates. If the coordinates intersect