Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make AssetAction::Ignore not copy assets to imported_assets #12605

Merged
merged 1 commit into from
Mar 21, 2024
Merged
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
8 changes: 5 additions & 3 deletions crates/bevy_asset/src/processor/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -722,9 +722,7 @@ impl AssetProcessor {
(meta, Some(processor))
}
AssetActionMinimal::Ignore => {
let meta: Box<dyn AssetMetaDyn> =
Box::new(AssetMeta::<(), ()>::deserialize(&meta_bytes)?);
(meta, None)
return Ok(ProcessResult::Ignored);
}
};
(meta, meta_bytes, processor)
Expand Down Expand Up @@ -1038,6 +1036,7 @@ impl AssetProcessorData {
pub enum ProcessResult {
Processed(ProcessedInfo),
SkippedNotChanged,
Ignored,
}

/// The final status of processing an asset
Expand Down Expand Up @@ -1185,6 +1184,9 @@ impl ProcessorAssetInfos {
// "block until first pass finished" mode
info.update_status(ProcessStatus::Processed).await;
}
Ok(ProcessResult::Ignored) => {
debug!("Skipping processing (ignored) \"{:?}\"", asset_path);
}
Err(ProcessError::ExtensionRequired) => {
// Skip assets without extensions
}
Expand Down