The code quality of assets.rs was lacking. It was a bit too large, too public, under-documented, and overly-responsible. This PR makes a variety of changes mostly aimed at improving the assets module without changing core functionality.
This will likely be merged after the 0.8 release, and released in 0.9 instead (between bevy upgrades). This is so users can deal with the breaking changes at their own pace rather than having to deal with them when upgrading their projects to bevy 0.11. Though, the breaking changes here shouldn't affect users much under normal usage.
Non-breaking changes
New LdtkAssetPlugin moves the registration of the asset types out of plugin.rs
LdtkProject and LdtkLevel are given their own submodules of assets.
Some extension methods added to ldtk types are now given their own "impl" submodules in ldtk.
Breaking changes
BEGIN_COMMIT_OVERRIDE
refactor!: LdtkAsset renamed to LdtkProject (#206)
refactor!: LdtkProject::project and LdtkLevel::level fields have both been renamed to data (#206)
refactor!: All fields of LdtkProject and LdtkLevel are now privatized, and have immutable getter methods (#206)
refactor!: LevelMap and TilesetMap type aliases have been removed (#206)
refactor!: LdtkAsset and LdtkProject are now exported in new assets module instead of lib.rs (#206)
refactor!: asset Loader types are now private (#206)
END_COMMIT_OVERRIDE
The code quality of
assets.rs
was lacking. It was a bit too large, too public, under-documented, and overly-responsible. This PR makes a variety of changes mostly aimed at improving the assets module without changing core functionality.This will likely be merged after the
0.8
release, and released in0.9
instead (between bevy upgrades). This is so users can deal with the breaking changes at their own pace rather than having to deal with them when upgrading their projects to bevy0.11
. Though, the breaking changes here shouldn't affect users much under normal usage.Non-breaking changes
LdtkAssetPlugin
moves the registration of the asset types out ofplugin.rs
LdtkProject
andLdtkLevel
are given their own submodules ofassets
.ldtk
types are now given their own "impl
" submodules inldtk
.Breaking changes
BEGIN_COMMIT_OVERRIDE refactor!:
LdtkAsset
renamed toLdtkProject
(#206) refactor!:LdtkProject::project
andLdtkLevel::level
fields have both been renamed todata
(#206) refactor!: All fields ofLdtkProject
andLdtkLevel
are now privatized, and have immutable getter methods (#206) refactor!:LevelMap
andTilesetMap
type aliases have been removed (#206) refactor!:LdtkAsset
andLdtkProject
are now exported in newassets
module instead oflib.rs
(#206) refactor!: assetLoader
types are now private (#206) END_COMMIT_OVERRIDE