Turn on dynamic linking
This commit is contained in:
parent
798f2d491b
commit
deb18f852b
10
Cargo.lock
generated
10
Cargo.lock
generated
|
@ -196,6 +196,7 @@ version = "0.5.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "c6b14f8ba7c373fdf7bd27547bb95f2849b2569bf02bbf3d19ca54e9d692de4f"
|
checksum = "c6b14f8ba7c373fdf7bd27547bb95f2849b2569bf02bbf3d19ca54e9d692de4f"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
"bevy_dylib",
|
||||||
"bevy_internal",
|
"bevy_internal",
|
||||||
"syn",
|
"syn",
|
||||||
]
|
]
|
||||||
|
@ -308,6 +309,15 @@ dependencies = [
|
||||||
"parking_lot",
|
"parking_lot",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "bevy_dylib"
|
||||||
|
version = "0.5.0"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "efa62c7c03470969539a07337bf8c5694c0b952678fd081d68b6331842134b85"
|
||||||
|
dependencies = [
|
||||||
|
"bevy_internal",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "bevy_dynamic_plugin"
|
name = "bevy_dynamic_plugin"
|
||||||
version = "0.5.0"
|
version = "0.5.0"
|
||||||
|
|
|
@ -5,5 +5,6 @@ edition = "2021"
|
||||||
|
|
||||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||||
|
|
||||||
[dependencies]
|
[dependencies.bevy]
|
||||||
bevy = "0.5"
|
version = "0.5"
|
||||||
|
features = ["dynamic"]
|
|
@ -38,6 +38,7 @@ fn setup(
|
||||||
commands.spawn_bundle(OrthographicCameraBundle::new_2d());
|
commands.spawn_bundle(OrthographicCameraBundle::new_2d());
|
||||||
commands.spawn_bundle(UiCameraBundle::default());
|
commands.spawn_bundle(UiCameraBundle::default());
|
||||||
|
|
||||||
|
// create the player
|
||||||
state.player.entity = Some(
|
state.player.entity = Some(
|
||||||
commands
|
commands
|
||||||
.spawn_bundle(SpriteBundle {
|
.spawn_bundle(SpriteBundle {
|
||||||
|
@ -101,6 +102,7 @@ fn movement(
|
||||||
moved = true;
|
moved = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// limit movement of player
|
||||||
game.player.x = game.player.x.min(435).max(-435);
|
game.player.x = game.player.x.min(435).max(-435);
|
||||||
game.player.y = game.player.y.min(285).max(-285);
|
game.player.y = game.player.y.min(285).max(-285);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue