-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Closed
Labels
A-AssetsLoad files from disk to use for things like images, models, and soundsLoad files from disk to use for things like images, models, and soundsC-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behavior
Description
Bevy version
0.5.0.
Operating system & version
Windows 10.
What you did
warn!(
"resource_handle: {:?} {:?} {}",
resource_handle,
asset_server.get_load_state(resource_handle.clone()),
resource_assets.get(resource_handle).is_some(),
);
-
Run the ui example (
cargo run --example=ui). -
If you manually click on the language change buttons, then everything is ok.
But if you use a mouse macro (or something else) for a very fast click, then the example ends with an error. -
Log output:
WARN bevy_fluent::assets::localization: resource_handle: StrongHandle<ResourceAsset>(AssetPathId(AssetPathId(SourcePathId(17015584791912148938), LabelId(6298619649789039366)))) Loaded true
WARN bevy_fluent::assets::localization: resource_handle: StrongHandle<ResourceAsset>(AssetPathId(AssetPathId(SourcePathId(2475016618522967226), LabelId(6298619649789039366)))) Loaded true
WARN bevy_fluent::assets::localization: resource_handle: StrongHandle<ResourceAsset>(AssetPathId(AssetPathId(SourcePathId(17610828258912988862), LabelId(6298619649789039366)))) Loaded false
WARN bevy_fluent::assets::localization: resource_handle: StrongHandle<ResourceAsset>(AssetPathId(AssetPathId(SourcePathId(17872065453730569751), LabelId(6298619649789039366)))) Loaded falseYou can see that the last two assets will have the status Loaded but get method return None.
What you expected to happen
For each asset that has LoadState::Loaded status, Assets.get always return Some.
What actually happened
You can see that some assets will have the status Loaded but get method return None.
Metadata
Metadata
Assignees
Labels
A-AssetsLoad files from disk to use for things like images, models, and soundsLoad files from disk to use for things like images, models, and soundsC-BugAn unexpected or incorrect behaviorAn unexpected or incorrect behavior