Usage with bevy_asset_loader #150
Replies: 1 comment
-
Sorry I didn't see this. I would eventually like to improve the ability to access the dependent assets loaded by the plugin. There's some plans to make That being said, is there some reason why you can't use If you really do need to load it separately, one pattern I find myself using a lot is the "blueprint" pattern, where I give the entity a marker component of some sort using I'm not 100% sure, but I don't think loading the same |
Beta Was this translation helpful? Give feedback.
-
Does anyone have any insight into the best way to use
bevy_ecs_ldtk
andbevy_asset_loader
together? I'm new to bevy, so excuse any ignorance.My various bundles already have a
SpriteSheetBundle
in them which usesbevy_asset_loader
to clone a handle for thetexture_atlas
from theResources
. I'm stumbling on how to use this same process whenbevy_ecs_ldtk
is handling the spawning of the entities. For that matter, drawing the tiles, as well.Perhaps I'm misunderstanding how things work and how things have to be done in the real world, but it seems weird to me that Ldtk is loading textures and sprites in its editor that this crate can then use within bevy, while also needing a developer to load textures and sprites a more traditional way. It's definitely premature optimization on my part, but it doesn't seem right to be loading the same sprite sheets twice.
I searched a bit and found @jrasanen had a PR mentioning improving ergonomics with
bevy_asset_loader
(#90), so I know I'm not the first person to give this combination a shot.Basically, what's the optimal way to load assets with
bevy_asset_loader
and applying those assets to levels assembled in Ldtk usingbevy_ecs_ldtk
?Beta Was this translation helpful? Give feedback.
All reactions