You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+8Lines changed: 8 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,14 @@
1
1
<!-- next-header -->
2
2
## [Unreleased] - ReleaseDate
3
3
4
+
### New
5
+
6
+
- The `collider` example can be installed globally with `cargo install rusty_engine --example collider` and run in the root of your own project with `collider assets/some-image.png`.
7
+
8
+
### Fixed
9
+
10
+
- The `collider` example can now load sprites from anywhere inside `assets/`, instead of only from inside `assets/sprite/`.
Copy file name to clipboardExpand all lines: tutorial/src/65-sprite-collider.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,14 +34,14 @@ All of the sprite presets in the game already have colliders, so you only have t
34
34
35
35
If you create a new sprite using your own image, and you want it to produce `CollisionEvent`s, then you need to create a collider for that sprite.
36
36
37
-
Creating colliders from scratch is quite tedius, so there is an "example" program called `collider` that you can use to create a collider! To run `collider`, clone the [`rusty_engine`](https://github.com/CleanCut/rusty_engine/) repository, place your image file in the `assets/sprite` directory (let's call it `db.png`), and then run:
37
+
Creating colliders from scratch is quite tedius, so there is an "example" program called `collider` that you can use to create a collider! To run `collider`, clone the [`rusty_engine`](https://github.com/CleanCut/rusty_engine/) repository, place your image file in the `assets` directory (let's call it `db.png`), and then run:
38
38
39
39
```text
40
-
$ cargo run --release --example collider assets/sprite/db.png
40
+
$ cargo run --release --example collider assets/db.png
41
41
```
42
42
43
43
Then follow the directions to create (or re-create) a collider and write it to a file.
44
44
45
45
<imgwidth="1392"alt="Screen Shot 2021-12-26 at 10 45 40 PM"src="https://user-images.githubusercontent.com/5838512/147438683-c8af2db7-66dd-463c-a269-d03f37869496.png">
46
46
47
-
Once you have a good collider created, copy (or move) both your image and `.collider`file to your own project, under the `assets/sprite` directory.
47
+
Once you have a good collider created, copy (or move) both your image and `.collider`files to your own project, under the `assets/` directory somewhere, and then [add the sprite to your game](55-sprite-creation.md)
0 commit comments