Skip to content

Commit b09d10b

Browse files
authored
chore(main): release 0.11.0 (#332)
🤖 I have created a release *beep* *boop* --- ## [0.11.0](v0.10.0...v0.11.0) (2024-12-23) ### ⚠ BREAKING CHANGES * upgrade to bevy and bevy_ecs_tilemap 0.15 ([#340](#340)) ### Features * upgrade to bevy and bevy_ecs_tilemap 0.15 ([#340](#340)) ([f44a281](f44a281)) ### Documentation Changes * refactor platformer example by topic ([#329](#329)) ([f59e5e5](f59e5e5)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
1 parent 690f1f5 commit b09d10b

14 files changed

+56
-40
lines changed

CHANGELOG.md

+16
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,21 @@
11
# Changelog
22

3+
## [0.11.0](https://github.com/Trouv/bevy_ecs_ldtk/compare/v0.10.0...v0.11.0) (2024-12-23)
4+
5+
6+
### ⚠ BREAKING CHANGES
7+
8+
* upgrade to bevy and bevy_ecs_tilemap 0.15 ([#340](https://github.com/Trouv/bevy_ecs_ldtk/issues/340))
9+
10+
### Features
11+
12+
* upgrade to bevy and bevy_ecs_tilemap 0.15 ([#340](https://github.com/Trouv/bevy_ecs_ldtk/issues/340)) ([f44a281](https://github.com/Trouv/bevy_ecs_ldtk/commit/f44a2814faf3f200232800aeb9e67f7c85f7278e))
13+
14+
15+
### Documentation Changes
16+
17+
* refactor platformer example by topic ([#329](https://github.com/Trouv/bevy_ecs_ldtk/issues/329)) ([f59e5e5](https://github.com/Trouv/bevy_ecs_ldtk/commit/f59e5e588026922620c1981108828e1e3ae6153f))
18+
319
## [0.10.0](https://github.com/Trouv/bevy_ecs_ldtk/compare/v0.9.0...v0.10.0) (2024-07-20)
420

521

Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "bevy_ecs_ldtk"
33
description = "An ECS-friendly ldtk plugin for bevy."
4-
version = "0.10.0"
4+
version = "0.11.0"
55
edition = "2021"
66
authors = ["Trevor Lovell <trevorlovelldesign@gmail.com>"]
77
repository = "https://github.com/Trouv/bevy_ecs_ldtk"
@@ -14,7 +14,7 @@ exclude = ["assets/*", "repo/*", "scripts/*"]
1414
members = ["macros"]
1515

1616
[dependencies]
17-
bevy_ecs_ldtk_macros = { version = "0.10.0", optional = true, path = "macros" }
17+
bevy_ecs_ldtk_macros = { version = "0.11.0", optional = true, path = "macros" }
1818
bevy_ecs_tilemap = { version = "0.15.0", default-features = false }
1919
bevy = { version = "0.15", default-features = false, features = [
2020
"bevy_sprite",

README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,13 @@ For less common use cases, strategies that leverage this plugin's ECS constructs
3030

3131
## Documentation
3232
Documentation for this plugin is available in two main places.
33-
- API reference on [docs.rs](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/) <!-- x-release-please-version -->
34-
- Tutorials, Explanation, and Guides in the [`bevy_ecs_ldtk` book](https://trouv.github.io/bevy_ecs_ldtk/v0.10.0/index.html) <!-- x-release-please-version -->
33+
- API reference on [docs.rs](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/) <!-- x-release-please-version -->
34+
- Tutorials, Explanation, and Guides in the [`bevy_ecs_ldtk` book](https://trouv.github.io/bevy_ecs_ldtk/v0.11.0/index.html) <!-- x-release-please-version -->
3535

3636
In the book, the following chapters are good jumping-off points for beginners:
37-
- [*Tile-based Game* tutorial](https://trouv.github.io/bevy_ecs_ldtk/v0.10.0/tutorials/tile-based-game/index.html) <!-- x-release-please-version -->
38-
- [*Level Selection* explanation](https://trouv.github.io/bevy_ecs_ldtk/v0.10.0/explanation/level-selection.html) <!-- x-release-please-version -->
39-
- [*Game Logic Integration* explanation](https://trouv.github.io/bevy_ecs_ldtk/v0.10.0/explanation/game-logic-integration.html) <!-- x-release-please-version -->
37+
- [*Tile-based Game* tutorial](https://trouv.github.io/bevy_ecs_ldtk/v0.11.0/tutorials/tile-based-game/index.html) <!-- x-release-please-version -->
38+
- [*Level Selection* explanation](https://trouv.github.io/bevy_ecs_ldtk/v0.11.0/explanation/level-selection.html) <!-- x-release-please-version -->
39+
- [*Game Logic Integration* explanation](https://trouv.github.io/bevy_ecs_ldtk/v0.11.0/explanation/game-logic-integration.html) <!-- x-release-please-version -->
4040

4141
Cargo examples are also available in this repository:
4242
```sh

book/src/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Some resources for learning Bevy include those listed on the [Bevy website](http
3232
LDtk also provides documentation on [its website](https://ldtk.io/docs/).
3333

3434
`bevy_ecs_ldtk`'s [source code](https://github.com/Trouv/bevy_ecs_ldtk) is available on github.
35-
This repository also contains [cargo examples](https://github.com/Trouv/bevy_ecs_ldtk/tree/v0.10.0/examples), which can be run after cloning the repository using `$ cargo run --example example-name`. <!-- x-release-please-version -->
35+
This repository also contains [cargo examples](https://github.com/Trouv/bevy_ecs_ldtk/tree/v0.11.0/examples), which can be run after cloning the repository using `$ cargo run --example example-name`. <!-- x-release-please-version -->
3636
These examples may be difficult to follow on their own, and many of their strategies are described in this book.
3737
When viewing these examples, be careful to checkout the correct git tag for the version of the plugin you are using.
3838
Some changes may have been made to the plugin or to the examples on the `main` branch that are not released yet, and trying to apply these to the version of the plugin you are using can lead to errors.

book/src/explanation/anatomy-of-the-world.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Anatomy of the World
2-
Once an [`LdtkWorldBundle`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LdtkWorldBundle.html) is spawned, [levels are selected](level-selection.md), and the associated assets finish loading, the level spawning process begins. <!-- x-release-please-version -->
2+
Once an [`LdtkWorldBundle`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LdtkWorldBundle.html) is spawned, [levels are selected](level-selection.md), and the associated assets finish loading, the level spawning process begins. <!-- x-release-please-version -->
33
The result is a deeply nested hierarchy of entities which can be difficult to navigate, but predictable.
44
It can be useful to write code that makes assumptions about the relationships between `bevy_ecs_ldtk` entities.
55
To assist with this, this chapter will explain the anatomy of a `bevy_ecs_ldtk` world.
@@ -8,16 +8,16 @@ To assist with this, this chapter will explain the anatomy of a `bevy_ecs_ldtk`
88
The basic hierarchy of spawned entities and their identifying components/bundles are as follows.
99
This does exclude some special cases which are explained in more detail below.
1010
Each bullet indent indicates a parent/child relationship.
11-
- The world entity, with an [`LdtkWorldBundle`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LdtkWorldBundle.html) bundle. <!-- x-release-please-version -->
12-
- The level entities, with a [`LevelIid`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LevelIid.html) component. <!-- x-release-please-version -->
13-
- For Entity layers - a layer entity with just a [`LayerMetadata`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LayerMetadata.html) component. <!-- x-release-please-version -->
14-
- LDtk Entity entities, with an [`EntityInstance`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/ldtk/struct.EntityInstance.html) component, or possibly others if you're using [`LdtkEntity` registration](game-logic-integration.html#ldtkentity-and-ldtkintcell-registration). <!-- x-release-please-version -->
15-
- For Tile/AutoTile/IntGrid layers: `bevy_ecs_tilemap` tilemap entities, with a [`TilemapBundle`](https://docs.rs/bevy_ecs_tilemap/latest/bevy_ecs_tilemap/type.TilemapBundle.html) **and** a [`LayerMetadata`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LayerMetadata.html) component. <!-- x-release-please-version -->
16-
- For IntGrid layers - tile entities with an [`IntGridCell`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.IntGridCell.html) component, or possibly others if you're using [`LdtkIntCell` registration](game-logic-integration.html#ldtkentity-and-ldtkintcell-registration). <!-- x-release-please-version -->
11+
- The world entity, with an [`LdtkWorldBundle`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LdtkWorldBundle.html) bundle. <!-- x-release-please-version -->
12+
- The level entities, with a [`LevelIid`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LevelIid.html) component. <!-- x-release-please-version -->
13+
- For Entity layers - a layer entity with just a [`LayerMetadata`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LayerMetadata.html) component. <!-- x-release-please-version -->
14+
- LDtk Entity entities, with an [`EntityInstance`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/ldtk/struct.EntityInstance.html) component, or possibly others if you're using [`LdtkEntity` registration](game-logic-integration.html#ldtkentity-and-ldtkintcell-registration). <!-- x-release-please-version -->
15+
- For Tile/AutoTile/IntGrid layers: `bevy_ecs_tilemap` tilemap entities, with a [`TilemapBundle`](https://docs.rs/bevy_ecs_tilemap/latest/bevy_ecs_tilemap/type.TilemapBundle.html) **and** a [`LayerMetadata`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LayerMetadata.html) component. <!-- x-release-please-version -->
16+
- For IntGrid layers - tile entities with an [`IntGridCell`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.IntGridCell.html) component, or possibly others if you're using [`LdtkIntCell` registration](game-logic-integration.html#ldtkentity-and-ldtkintcell-registration). <!-- x-release-please-version -->
1717
- For Tile/AutoTile layers (or IntGrid layers with AutoTile functionality) - `bevy_ecs_tilemap` tile entities, with a [`TileBundle`](https://docs.rs/bevy_ecs_tilemap/latest/bevy_ecs_tilemap/tiles/struct.TileBundle.html) bundle.
1818

1919
## Worldly Entities
20-
The [`LdtkEntity` derive macro](game-logic-integration.html#ldtkentity-and-ldtkintcell-registration) allows you to define entities as ["worldly"](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/app/trait.LdtkEntity.html#worldly). <!-- x-release-please-version -->
20+
The [`LdtkEntity` derive macro](game-logic-integration.html#ldtkentity-and-ldtkintcell-registration) allows you to define entities as ["worldly"](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/app/trait.LdtkEntity.html#worldly). <!-- x-release-please-version -->
2121
The intention of this feature is to support entities that are allowed to persist and traverse between levels, like a player in a GridVania layout.
2222

2323
One consequence of an entity being worldly is a change in its placement in the above hierarchy.
@@ -32,8 +32,8 @@ For example, if the worldly player entity traverses far enough away that their o
3232
LDtk allows you to associate metadata with particular tiles in a tileset.
3333
`bevy_ecs_ldtk` responds to this by adding additional components to tiles that have metadata *in addition to* those described in the [hierarchy](#hierarchy):
3434

35-
- [`TileMetadata`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.TileMetadata.html) <!-- x-release-please-version -->
36-
- [`TileEnumTags`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.TileEnumTags.html) <!-- x-release-please-version -->
35+
- [`TileMetadata`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.TileMetadata.html) <!-- x-release-please-version -->
36+
- [`TileEnumTags`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.TileEnumTags.html) <!-- x-release-please-version -->
3737

3838
Naturally, this can only occur in Tile/AutoTile layers (or IntGrid layers with AutoTile functionality), since the metadata is defined on tilesets.
3939

@@ -43,7 +43,7 @@ LDtk allows you to supply a background color and a background image for individu
4343
The background color is spawned as a normal bevy [`Sprite`](https://docs.rs/bevy/latest/bevy/prelude/struct.Sprite.html), as a child of the level entity.
4444
The background image, if it exists, is also spawned as a `Sprite`.
4545

46-
These background sprites can be disabled (not spawned) using the settings resource [`LdtkSettings`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LdtkSettings.html): <!-- x-release-please-version -->
46+
These background sprites can be disabled (not spawned) using the settings resource [`LdtkSettings`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LdtkSettings.html): <!-- x-release-please-version -->
4747
```rust,no_run
4848
use bevy::prelude::*;
4949
use bevy_ecs_ldtk::prelude::*;
@@ -65,7 +65,7 @@ In other words, a single layer can have more than one tile in the same location.
6565

6666
`bevy_ecs_tilemap` tilemaps only allow one tile per position.
6767
So, `bevy_ecs_ldtk` supports layers with colliding tiles by spawning multiple tilemaps.
68-
Each of them will have the same [`LayerMetadata`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LayerMetadata.html) component. <!-- x-release-please-version -->
68+
Each of them will have the same [`LayerMetadata`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LayerMetadata.html) component. <!-- x-release-please-version -->
6969
This means that users cannot assume that there will be only one `LayerMetadata` entity per layer.
7070

7171

book/src/explanation/game-logic-integration.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ Without any intervention, the bundle's fields are constructed using the bundle's
3737
However, various attributes are available to override this behavior, like `#[sprite]` in the above example.
3838
This attribute gives the entity a sprite using the tileset in its LDtk editor visual.
3939
For documentation about all the available attributes, check out the API reference for these traits:
40-
- [`LdtkEntity`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/app/trait.LdtkEntity.html) <!-- x-release-please-version -->
41-
- [`LdtkIntCell`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/app/trait.LdtkIntCell.html) <!-- x-release-please-version -->
40+
- [`LdtkEntity`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/app/trait.LdtkEntity.html) <!-- x-release-please-version -->
41+
- [`LdtkIntCell`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/app/trait.LdtkIntCell.html) <!-- x-release-please-version -->
4242

4343
This approach is suitable for many common, simple use cases.
4444
There's also room for more granular, component-level customization within some of the attributes, like `#[with(...)]` or `#[from_entity_instance]`.

book/src/explanation/level-selection.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# Level Selection
2-
Once you have spawned an [`LdtkWorldBundle`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LdtkWorldBundle.html) with a handle pointing to your LDtk project file, the levels you have selected will spawn as children of the world bundle. <!-- x-release-please-version -->
2+
Once you have spawned an [`LdtkWorldBundle`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LdtkWorldBundle.html) with a handle pointing to your LDtk project file, the levels you have selected will spawn as children of the world bundle. <!-- x-release-please-version -->
33
You have a couple options for selecting levels, which will be discussed in this chapter.
44

55
## `LevelSelection` resource
6-
The highest-level option for selecting a level to spawn is using the [`LevelSelection`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/enum.LevelSelection.html) resource. <!-- x-release-please-version -->
6+
The highest-level option for selecting a level to spawn is using the [`LevelSelection`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/enum.LevelSelection.html) resource. <!-- x-release-please-version -->
77
This resource allows you to specify a particular level either by its indices in the project/world, its identifier, its iid, or its uid.
88
Once this resource is added or changed, levels will be spawned/despawned in order to match your selection.
99

1010
One additional feature worth pointing out is loading level neighbors.
11-
You can enable this with the settings resource [`LdtkSettings`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LdtkSettings.html): <!-- x-release-please-version -->
11+
You can enable this with the settings resource [`LdtkSettings`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LdtkSettings.html): <!-- x-release-please-version -->
1212

1313
```rust,no_run
1414
use bevy::prelude::*;
@@ -33,7 +33,7 @@ This can be especially useful for GridVania/Free-style worlds where it's importa
3333
Note: this *only* works if you are using the `LevelSelection` resource.
3434

3535
## `LevelSet` component
36-
One component in the `LdtkWorldBundle` is [`LevelSet`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.LevelSet.html). <!-- x-release-please-version -->
36+
One component in the `LdtkWorldBundle` is [`LevelSet`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.LevelSet.html). <!-- x-release-please-version -->
3737
This component can be used for lower-level level selection.
3838
Instead of selecting one level globally with a `LevelSelection` resource, you can select a specific set of levels by their iids.
3939
From the `level_set` cargo example:

book/src/how-to-guides/respawn-levels-and-worlds.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Respawn Levels and Worlds
2-
Internally, `bevy_ecs_ldtk` uses a [`Respawn`](https://docs.rs/bevy_ecs_ldtk/0.10.0/bevy_ecs_ldtk/prelude/struct.Respawn.html) component on worlds and levels to assist in the spawning process. <!-- x-release-please-version -->
2+
Internally, `bevy_ecs_ldtk` uses a [`Respawn`](https://docs.rs/bevy_ecs_ldtk/0.11.0/bevy_ecs_ldtk/prelude/struct.Respawn.html) component on worlds and levels to assist in the spawning process. <!-- x-release-please-version -->
33
This can be leveraged by users to implement a simple level restart feature, or an even more heavy-handed world restart feature.
44

55
This code is from the `collectathon` cargo example.

macros/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "bevy_ecs_ldtk_macros"
33
description = "Derive macros for bevy_ecs_ldtk."
4-
version = "0.10.0"
4+
version = "0.11.0"
55
edition = "2021"
66
authors = ["Trevor Lovell <trevorlovelldesign@gmail.com>"]
77
license = "MIT OR Apache-2.0"

src/app/ldtk_entity.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ use std::{collections::HashMap, marker::PhantomData};
139139
/// [Worldly] entities don't despawn when their birth level despawns, and they don't respawn when
140140
/// their birth level respawns.
141141
/// For a more detailed explanation, please see the
142-
/// [*Worldly Entities*](https://trouv.github.io/bevy_ecs_ldtk/v0.10.0/explanation/anatomy-of-the-world.html#worldly-entities) <!-- x-release-please-version -->
142+
/// [*Worldly Entities*](https://trouv.github.io/bevy_ecs_ldtk/v0.11.0/explanation/anatomy-of-the-world.html#worldly-entities) <!-- x-release-please-version -->
143143
/// section of the `bevy_ecs_ldtk` book.
144144
/// ```
145145
/// # use bevy::prelude::*;

src/components/level_set.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use crate::LevelIid;
66
/// [`Component`] that determines the desired levels to be spawned in an [`LdtkWorldBundle`].
77
///
88
/// For more explanation and comparison of options for selecting levels to spawn, see the
9-
/// [*Level Selection*](https://trouv.github.io/bevy_ecs_ldtk/v0.10.0/explanation/level-selection.html) <!-- x-release-please-version -->
9+
/// [*Level Selection*](https://trouv.github.io/bevy_ecs_ldtk/v0.11.0/explanation/level-selection.html) <!-- x-release-please-version -->
1010
/// chapter of the `bevy_ecs_ldtk` book.
1111
///
1212
/// [`Component`]: https://docs.rs/bevy/latest/bevy/ecs/prelude/trait.Component.html

0 commit comments

Comments
 (0)