From 1579c3d97284d38d59808cb389903ece60005df0 Mon Sep 17 00:00:00 2001 From: Joe Ardent Date: Sun, 8 May 2022 10:58:48 -0700 Subject: [PATCH] Builds and runs, but physics is fucked. --- Cargo.lock | 438 +++++++++++++++++++++++++++----------------------- Cargo.toml | 9 +- src/action.rs | 35 ++-- src/bike.rs | 152 ++++++++---------- src/camera.rs | 44 +++-- src/glamor.rs | 2 +- src/input.rs | 23 ++- src/planet.rs | 36 ++--- src/ui.rs | 4 +- 9 files changed, 376 insertions(+), 367 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 0eb9194..54ae1ba 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -30,7 +30,7 @@ version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" dependencies = [ - "getrandom 0.2.5", + "getrandom 0.2.6", "once_cell", "version_check", ] @@ -73,9 +73,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.56" +version = "1.0.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4361135be9122e0870de935d7c439aef945b9f9ddd4199a553b5270b49c82a27" +checksum = "08f9b8508dccb7687a1d6c4ce66b2b0ecef467c94667de27d8d7fe1f8d2a9cdc" [[package]] name = "approx" @@ -140,9 +140,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "base-x" -version = "0.2.8" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4521f3e3d031370679b3b140beb36dfe4801b09ac77e30c61941f97df3ef28b" +checksum = "dc19a4937b4fbd3fe3379793130e42060d10627a360f2127802b10b87e7baf74" [[package]] name = "base64" @@ -152,18 +152,18 @@ checksum = "904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fd" [[package]] name = "bevy" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97342ea2f3bad36be2ded1d1fbd569ff83147b70697f12f1579e87a7480afa36" +checksum = "4fce306d40a111309ee61d4626efbafccdd46bb80657122c38061fa7264c08e4" dependencies = [ "bevy_internal", ] [[package]] name = "bevy-crevice-derive" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4cf594c9277eb1e426f45a00eaf70aa9ffdf479268d7e4538270263811e20bc" +checksum = "191a752a01c3402deb24320acf42288bf822e5d22f19ae1d903797f02e9b0c33" dependencies = [ "bevy_macro_utils", "proc-macro2", @@ -173,9 +173,9 @@ dependencies = [ [[package]] name = "bevy_app" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fe3d3f4140fb11cd294f43be7cb66a5783d9277ba0270743e2860e32b25ab5" +checksum = "32660ae99fa3498ca379de28b7e2f447e6531b0e432bf200901efeec075553c1" dependencies = [ "bevy_derive", "bevy_ecs", @@ -187,9 +187,9 @@ dependencies = [ [[package]] name = "bevy_asset" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb68a0259e2f857a32c4f05eb9b9447db1072297c61864ad07d02fea1838bde9" +checksum = "f2afd395240087924ba49c8cae2b00d007aeb1db53ee726a543b1e90dce2d3ab" dependencies = [ "anyhow", "bevy_app", @@ -214,9 +214,9 @@ dependencies = [ [[package]] name = "bevy_core" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c156430a5312c04a1b25fa434eeeab6349a41c6bb96ea0385406d53b3c43658" +checksum = "12c0f8614b6014671ab60bacb8bf681373d08b0bb15633b8ef72b895cf966d29" dependencies = [ "bevy_app", "bevy_derive", @@ -230,22 +230,23 @@ dependencies = [ [[package]] name = "bevy_core_pipeline" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b422dca94195c904964ab21bc4557fbd11f692c299d46e38364715ac931841e" +checksum = "74d570bc9310196190910a5b1ffd8c8c35bd6b73f918d0651ae3c3d4e57be9a7" dependencies = [ "bevy_app", "bevy_asset", "bevy_core", "bevy_ecs", "bevy_render", + "bevy_utils", ] [[package]] name = "bevy_crevice" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c684de72f710da0a701d1d2fe2a481241709d66f43215bcc9d7f9f0818d1cb15" +checksum = "3da0a284fb26c02cb96ef4d5bbf4de5fad7e1a901730035a61813bf64e28482e" dependencies = [ "bevy-crevice-derive", "bytemuck", @@ -255,9 +256,9 @@ dependencies = [ [[package]] name = "bevy_derive" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "918dc0dff01e8b4e8f989db89d74fd4042810ea80a70642d0459b3c265995e59" +checksum = "6abddf2ed415f31d28a9bf9ab3c0bc857e98a722858d38dba65bdda481f8d714" dependencies = [ "bevy_macro_utils", "quote", @@ -266,9 +267,9 @@ dependencies = [ [[package]] name = "bevy_diagnostic" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adbe98f48873d4b20f6479723de18d957f4bc00c653efd36c245e6a66d6e8b71" +checksum = "6ebf72ea058cfc379756e9da7de6861174e1860504f41e3e5a46d5b1c35d6644" dependencies = [ "bevy_app", "bevy_core", @@ -279,9 +280,9 @@ dependencies = [ [[package]] name = "bevy_ecs" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6daf05da2680a14b17a4b669879fa7186abb80e7fbe400fb02c0c62628d1e200" +checksum = "79e67dd06b14e787d2026fe6e2b63f67482afcc62284f20ea2784d8b0662e95f" dependencies = [ "async-channel", "bevy_ecs_macros", @@ -297,9 +298,9 @@ dependencies = [ [[package]] name = "bevy_ecs_macros" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7e9e664b3ea45cfc9ab3251ee0255dfa6410f675b3a405e7bac8e59b2d76aa9" +checksum = "718923a491490bd81074492d61fc08134f9c62a29ba8666818cd7a6630421246" dependencies = [ "bevy_macro_utils", "proc-macro2", @@ -309,9 +310,9 @@ dependencies = [ [[package]] name = "bevy_gilrs" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b457f720b1c54ede34afd6007beae3708503c0dd7a4ab4b416e36cb8bbd05ac1" +checksum = "15b164983e8057a1a730412a7c26ccc540d9ce76d2c6ab68edd258a0baeb1762" dependencies = [ "bevy_app", "bevy_ecs", @@ -322,9 +323,9 @@ dependencies = [ [[package]] name = "bevy_gltf" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34e4711f4f77542dccd59eec249c98f02e34e28a25ee079c14cd351061d08e5c" +checksum = "2e07bda7721091c1a683343d466132dc69dec65aa83d8c9e328a2fb3431f03be" dependencies = [ "anyhow", "base64", @@ -332,6 +333,7 @@ dependencies = [ "bevy_asset", "bevy_core", "bevy_ecs", + "bevy_hierarchy", "bevy_log", "bevy_math", "bevy_pbr", @@ -346,10 +348,23 @@ dependencies = [ ] [[package]] -name = "bevy_input" -version = "0.6.0" +name = "bevy_hierarchy" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33989693efa636960dd40e540029ed7b7bc1af2f3eef26c009555b5e2a4e185a" +checksum = "2f407f152f35541a099484200afe3b0ca09ce625469e8233dcdc264d6f88e01a" +dependencies = [ + "bevy_app", + "bevy_ecs", + "bevy_reflect", + "bevy_utils", + "smallvec", +] + +[[package]] +name = "bevy_input" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff4ec4f6e38ef1b41ff68ec7badd6afc5c9699191e61e511c4abee91a5888afc" dependencies = [ "bevy_app", "bevy_ecs", @@ -359,9 +374,9 @@ dependencies = [ [[package]] name = "bevy_internal" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f92af28d95bba80d11840c24fa4ce8ff84ae27af1def2f5cf8a6891acce5d714" +checksum = "d518a8e5f526a9537fc8408a284caec7af22b23c3b23c0dee08bacc0930e2f1a" dependencies = [ "bevy_app", "bevy_asset", @@ -372,6 +387,7 @@ dependencies = [ "bevy_ecs", "bevy_gilrs", "bevy_gltf", + "bevy_hierarchy", "bevy_input", "bevy_log", "bevy_math", @@ -392,9 +408,9 @@ dependencies = [ [[package]] name = "bevy_log" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bf0083e72bf76cbfa6607311ac6baef2f4f7c9306c35942cece8c0589cd3e5e" +checksum = "943ec496720ded2ff62b292d8e5fc845817a504915f41b7c5fd12b1380300f75" dependencies = [ "android_log-sys", "bevy_app", @@ -407,9 +423,9 @@ dependencies = [ [[package]] name = "bevy_macro_utils" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57cf90b3b67606d0818cdac6c9134eb66fa174959977a4abba893364a571a7cd" +checksum = "b7ddfc33a99547e36718e56e414541e461c74ec318ff987a1e9f4ff46d0dacbb" dependencies = [ "cargo-manifest", "quote", @@ -418,9 +434,9 @@ dependencies = [ [[package]] name = "bevy_math" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b0f9ebf2ef80a8fff3e5dca817594071004048cd089e72b9a1bf4e494b66112" +checksum = "20288df0f70ff258bbaffaf55209f1271a7436438591bbffc3d81e4d84b423f2" dependencies = [ "bevy_reflect", "glam", @@ -428,9 +444,9 @@ dependencies = [ [[package]] name = "bevy_pbr" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41724d89746d54f7f8c8e522f9d0b1232a8a289e0d270482175d23774dc2362a" +checksum = "06adee54840f18cfeda7af4cdc57608644fa840be076a562353f896bfdb9c694" dependencies = [ "bevy_app", "bevy_asset", @@ -449,9 +465,9 @@ dependencies = [ [[package]] name = "bevy_polyline" -version = "0.1.4" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0973d599ae862049333b74cb5216de1be07cf7db675b6dcc0e055006ab41be26" +checksum = "aff83a9ef2b8dee22c2c214e41c6b441ffebf9c6226b35f6e07cdeb4ab158eb5" dependencies = [ "bevy", "bitflags", @@ -460,20 +476,22 @@ dependencies = [ [[package]] name = "bevy_rapier3d" -version = "0.12.1" +version = "0.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5186c735d7aa202e982f93c71b444d34bf15fed44aca942f9b5f2940e3d06764" +checksum = "cf91c1d5cbddaec454a227d32eb9151705ebc23cf3ecd30874eed71cf5d9e663" dependencies = [ "bevy", + "bitflags", + "log", "nalgebra", "rapier3d", ] [[package]] name = "bevy_reflect" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d84ce8cbd484a39d67171831eaf72c20d2684de71f1e9d79333c8dd6d6f3ebca" +checksum = "4d0793107bc4b7c6bd04232d739fc8d70aa5fb313bfad6e850f91f79b2557eed" dependencies = [ "bevy_reflect_derive", "bevy_utils", @@ -488,9 +506,9 @@ dependencies = [ [[package]] name = "bevy_reflect_derive" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7af3100febf44583a7c052d1469fbdb411f56aa85729333a0ac106a016bd379c" +checksum = "81c88de8067d19dfde31662ee78e3ee6971e2df27715799f91b515b37a636677" dependencies = [ "bevy_macro_utils", "proc-macro2", @@ -501,9 +519,9 @@ dependencies = [ [[package]] name = "bevy_render" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac0d5409e5e3d48f3192f78e37bedea29aa0c674083e51aaa7e945496913d2c2" +checksum = "6a358da8255b704153913c3499b3693fa5cfe13a48725ac6e76b043fa5633bc8" dependencies = [ "anyhow", "bevy_app", @@ -523,7 +541,7 @@ dependencies = [ "downcast-rs", "futures-lite", "hex", - "hexasphere 6.1.0", + "hexasphere", "image", "naga", "once_cell", @@ -537,16 +555,16 @@ dependencies = [ [[package]] name = "bevy_scene" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21eb2b01e4d1b074c75ea59a92409739cac24b56b1c723491ef80936d50e95df" +checksum = "2ea240f2ffce9f58a5601cc5ead24111f577dc4c656452839eb1fdf4b7a28529" dependencies = [ "anyhow", "bevy_app", "bevy_asset", "bevy_ecs", + "bevy_hierarchy", "bevy_reflect", - "bevy_transform", "bevy_utils", "ron", "serde", @@ -556,9 +574,9 @@ dependencies = [ [[package]] name = "bevy_sprite" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66439831ff57c11c7fb2692e7ccf8d0551f4368a9908908d3c38f2da53115b33" +checksum = "5fcecfbc623410137d85a71a295ff7c16604b7be24529c9ea4b9a9881d7a142b" dependencies = [ "bevy_app", "bevy_asset", @@ -582,9 +600,9 @@ dependencies = [ [[package]] name = "bevy_tasks" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9dc4bce7f4cddbb489636092f52478b103dc26ee8526c585289bbdd9c0d0a99f" +checksum = "db2b0f0b86c8f78c53a2d4c669522f45e725ed9d9c3d734f54ec30876494e04e" dependencies = [ "async-channel", "async-executor", @@ -596,9 +614,9 @@ dependencies = [ [[package]] name = "bevy_text" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233c4bb933435e8e6c34a1310317fd7f8c6617526270de572e643816070b236a" +checksum = "a206112de011fd6baebaf476af69d87f4e38a1314b65e3c872060830d7c0b9fa" dependencies = [ "ab_glyph", "anyhow", @@ -620,23 +638,22 @@ dependencies = [ [[package]] name = "bevy_transform" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9974c494f9cc721df46d2ba27c6a8df2a955ed8360a23adabd2bd66d1f73fa8f" +checksum = "aa2f7a77900fb23f24ca312c1f8df3eb47a45161326f41e9b4ef05b039793503" dependencies = [ "bevy_app", "bevy_ecs", + "bevy_hierarchy", "bevy_math", "bevy_reflect", - "bevy_utils", - "smallvec", ] [[package]] name = "bevy_ui" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbdb34595bd7be349fba8038b970acbe632f70b98737318b2327c7c7cd557767" +checksum = "c65e79658d8a3d4da087a6fb8b229cfe1455cda2c4e8e6305b3b44fb46fb1d30" dependencies = [ "bevy_app", "bevy_asset", @@ -644,6 +661,7 @@ dependencies = [ "bevy_core_pipeline", "bevy_derive", "bevy_ecs", + "bevy_hierarchy", "bevy_input", "bevy_log", "bevy_math", @@ -662,13 +680,14 @@ dependencies = [ [[package]] name = "bevy_utils" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "252f6674aa3ba68bacfec506b91570a3cc206ad09b7ef4b23661959ef0246396" +checksum = "2f354c584812996febd48cc885f36b23004b49d6680e73fc95a69a2bb17a48e5" dependencies = [ "ahash", "bevy_derive", - "getrandom 0.2.5", + "getrandom 0.2.6", + "hashbrown", "instant", "tracing", "uuid", @@ -676,11 +695,12 @@ dependencies = [ [[package]] name = "bevy_window" -version = "0.6.0" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f4b52b766baf565e96f24f61dbc51bc85151f23202fed2b3650769f2edd0b21" +checksum = "04fe33d177e10b2984fa90c1d19496fc6f6e7b36d4442699d359e2b4b507873d" dependencies = [ "bevy_app", + "bevy_ecs", "bevy_math", "bevy_utils", "raw-window-handle", @@ -689,9 +709,9 @@ dependencies = [ [[package]] name = "bevy_winit" -version = "0.6.1" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0d4a4bed46200615e070897a551d2389d49cdaff048e825e7fa6caef4dc57c6" +checksum = "a7c0e3b94cc73907f8a9f82945ca006a39ed2ab401aca0974b47a007a468509f" dependencies = [ "approx", "bevy_app", @@ -741,18 +761,18 @@ checksum = "a4a45a46ab1f2412e53d3a0ade76ffad2025804294569aae387231a0cd6e0899" [[package]] name = "bytemuck" -version = "1.8.0" +version = "1.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e851ca7c24871e7336801608a4797d7376545b6928a10d32d75685687141ead" +checksum = "cdead85bdec19c194affaeeb670c0e41fe23de31459efd1c174d049269cf02cc" dependencies = [ "bytemuck_derive", ] [[package]] name = "bytemuck_derive" -version = "1.0.1" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e215f8c2f9f79cb53c8335e687ffd07d5bfcb6fe5fc80723762d0be46e7cc54" +checksum = "562e382481975bc61d11275ac5e62a19abd00b0547d99516a415336f183dcd0e" dependencies = [ "proc-macro2", "quote", @@ -1067,7 +1087,7 @@ dependencies = [ "bevy", "bevy_polyline", "bevy_rapier3d", - "hexasphere 7.0.0", + "hexasphere", "noise", "rand 0.8.5", "wgpu", @@ -1086,9 +1106,9 @@ dependencies = [ [[package]] name = "darling" -version = "0.13.1" +version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0d720b8683f8dd83c65155f0530560cba68cd2bf395f6513a483caee57ff7f4" +checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" dependencies = [ "darling_core", "darling_macro", @@ -1096,9 +1116,9 @@ dependencies = [ [[package]] name = "darling_core" -version = "0.13.1" +version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a340f241d2ceed1deb47ae36c4144b2707ec7dd0b649f894cb39bb595986324" +checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" dependencies = [ "fnv", "ident_case", @@ -1110,9 +1130,9 @@ dependencies = [ [[package]] name = "darling_macro" -version = "0.13.1" +version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72c41b3b7352feb3211a0d743dc5700a4e3b60f51bd2b368892d1e0f9a95f44b" +checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" dependencies = [ "darling_core", "quote", @@ -1174,9 +1194,9 @@ dependencies = [ [[package]] name = "euclid" -version = "0.22.6" +version = "0.22.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da96828553a086d7b18dcebfc579bd9628b016f86590d7453c115e490fa74b80" +checksum = "b52c2ef4a78da0ba68fbe1fd920627411096d2ac478f7f4c9f3a54ba6705bade" dependencies = [ "num-traits", ] @@ -1272,9 +1292,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d39cd93900197114fa1fcb7ae84ca742095eed9442088988ae74fa744e930e77" +checksum = "9be70c98951c83b8d2f8f60d7065fa6d5146873094452a1008da8c2f1e4205ad" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -1319,9 +1339,9 @@ dependencies = [ [[package]] name = "glam" -version = "0.20.2" +version = "0.20.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4fa84eead97d5412b2a20aed4d66612a97a9e41e08eababdb9ae2bf88667490" +checksum = "f43e957e744be03f5801a55472f593d43fabdebf25a4585db250f04d86b1675f" dependencies = [ "bytemuck", "mint", @@ -1342,9 +1362,9 @@ dependencies = [ [[package]] name = "gltf" -version = "0.16.0" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ff38b75359a0096dd0a8599b6e4f37a6ee41d5df300cc7669e62aafa697f7a2" +checksum = "00e0a0eace786193fc83644907097285396360e9e82e30f81a21e9b1ba836a3e" dependencies = [ "byteorder", "gltf-json", @@ -1353,9 +1373,9 @@ dependencies = [ [[package]] name = "gltf-derive" -version = "0.16.0" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f2a9333e0f9c7bca94dfc20bcf44fa12a61eeec662d6e007563ff748aa59c70" +checksum = "bdd53d6e284bb2bf02a6926e4cc4984978c1990914d6cd9deae4e31cf37cd113" dependencies = [ "inflections", "proc-macro2", @@ -1365,9 +1385,9 @@ dependencies = [ [[package]] name = "gltf-json" -version = "0.16.0" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1414d3a98cbaabdb2f134328b1f6036d14b282febc1df51952a435d2ca17fb6" +checksum = "9949836a9ec5e7f83f76fb9bbcbc77f254a577ebbdb0820867bc11979ef97cad" dependencies = [ "gltf-derive", "serde", @@ -1442,6 +1462,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ab5ef0d4909ef3724cc8cce6ccc8572c5c817592e9285f5464f8e86f8bd3726e" dependencies = [ "ahash", + "serde", ] [[package]] @@ -1459,16 +1480,6 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" -[[package]] -name = "hexasphere" -version = "6.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b219bdb56b14905fa5429636bfc4df0043626642d4586d069a82019130846f5" -dependencies = [ - "glam", - "lazy_static", -] - [[package]] name = "hexasphere" version = "7.0.0" @@ -1509,9 +1520,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "1.8.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282a6247722caba404c065016bbfa522806e51714c34f5dfc3e4a3a46fcb4223" +checksum = "0f647032dfaa1f8b6dc29bd3edb7bbef4861b8b8007ebb118d6db284fd59f6ee" dependencies = [ "autocfg", "hashbrown", @@ -1565,9 +1576,9 @@ checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" [[package]] name = "js-sys" -version = "0.3.56" +version = "0.3.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38fc24e30fd564ce974c02bf1d337caddff65be6cc4735a1f7eab22a7440f04" +checksum = "671a26f820db17c2a2750743f1dd03bafd15b98c9f30c7c2628c024c05d73397" dependencies = [ "wasm-bindgen", ] @@ -1590,9 +1601,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.121" +version = "0.2.125" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "efaa7b300f3b5fe8eb6bf21ce3895e1751d9665086af2d64b42f19701015ff4f" +checksum = "5916d2ae698f6de9bfb891ad7a8d65c09d232dc58cc4ac433c7da3b2fd84bc2b" [[package]] name = "libloading" @@ -1628,18 +1639,19 @@ dependencies = [ [[package]] name = "lock_api" -version = "0.4.6" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88943dd7ef4a2e5a4bfa2753aaab3013e34ce2533d1996fb18ef591e315e2b3b" +checksum = "327fa5b6a6940e4699ec49a9beae1ea4845c6bab9314e4f84ac68742139d8c53" dependencies = [ + "autocfg", "scopeguard", ] [[package]] name = "log" -version = "0.4.16" +version = "0.4.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6389c490849ff5bc16be905ae24bc913a9c8892e19b2341dbc175e14c341c2b8" +checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" dependencies = [ "cfg-if 1.0.0", ] @@ -1682,9 +1694,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.4.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "308cc39be01b73d0d18f82a0e7b2a3df85245f84af96fdddc5d202d27e47b86a" +checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" [[package]] name = "memoffset" @@ -1769,9 +1781,9 @@ dependencies = [ [[package]] name = "nalgebra" -version = "0.30.1" +version = "0.31.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb2d0de08694bed883320212c18ee3008576bfe8c306f4c3c4a58b4876998be" +checksum = "18a89248335f688e4bd994e6d030fd7e185eb41769b8c435395075425e100ac6" dependencies = [ "approx", "glam", @@ -1810,15 +1822,15 @@ dependencies = [ [[package]] name = "ndk-context" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e3c5cc68637e21fe8f077f6a1c9e0b9ca495bb74895226b476310f613325884" +checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b" [[package]] name = "ndk-glue" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1c68f70683c5fc9a747a383744206cd371741b2f0b31781ab6770487ec572e2" +checksum = "c71bee8ea72d685477e28bd004cfe1bf99c754d688cd78cad139eae4089484d4" dependencies = [ "android_logger", "lazy_static", @@ -1883,9 +1895,9 @@ dependencies = [ [[package]] name = "num-complex" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26873667bbbb7c5182d4a37c1add32cdf09f841af72da53318fdb81543c15085" +checksum = "97fbc387afefefd5e9e39493299f3069e14a140dd34dc19b4c1c1a8fddb6a790" dependencies = [ "num-traits", ] @@ -1903,9 +1915,9 @@ dependencies = [ [[package]] name = "num-integer" -version = "0.1.44" +version = "0.1.45" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2cc698a63b549a70bc047073d2949cce27cd1c7b0a4a862d08a8031bc2801db" +checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" dependencies = [ "autocfg", "num-traits", @@ -1913,9 +1925,9 @@ dependencies = [ [[package]] name = "num-iter" -version = "0.1.42" +version = "0.1.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2021c8337a54d21aca0d59a92577a029af9431cb59b909b03252b9c164fad59" +checksum = "7d03e6c028c5dc5cac6e2dec0efda81fc887605bb3d884578bb6d6bf7514e252" dependencies = [ "autocfg", "num-integer", @@ -1946,9 +1958,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.14" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a64b1ec5cda2586e284722486d802acf1f7dbdc623e2bfc57e65ca1cd099290" +checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" dependencies = [ "autocfg", "libm 0.2.2", @@ -2010,6 +2022,12 @@ version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "87f3e037eac156d1775da914196f0f37741a274155e34a0b7e427c35d2a2ecb9" +[[package]] +name = "optional" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "978aa494585d3ca4ad74929863093e87cac9790d81fe7aba2b3dc2890643a0fc" + [[package]] name = "owned_ttf_parser" version = "0.15.0" @@ -2062,11 +2080,12 @@ dependencies = [ [[package]] name = "parry3d" -version = "0.8.0" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c418a03e2ba297c931c530a690b305ce3b3dcc675caf16777f4f8565c8e84732" +checksum = "89cd07f0e1e9e207662f430a4e758c357fdf89450a548ef1ce59113822fd5fa7" dependencies = [ "approx", + "arrayvec", "bitflags", "downcast-rs", "either", @@ -2077,13 +2096,14 @@ dependencies = [ "simba", "slab", "smallvec", + "spade", ] [[package]] name = "paste" -version = "1.0.6" +version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0744126afe1a6dd7f394cb50a716dbe086cb06e255e53d8d0185d82828358fb5" +checksum = "0c520e05135d6e763148b6426a837e239041653ba7becd2e538c076c738025fc" [[package]] name = "percent-encoding" @@ -2103,15 +2123,15 @@ dependencies = [ [[package]] name = "pin-project-lite" -version = "0.2.8" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e280fbe77cc62c91527259e9442153f4688736748d24660126286329742b4c6c" +checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" [[package]] name = "pkg-config" -version = "0.3.24" +version = "0.3.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58893f751c9b0412871a09abd62ecd2a00298c6c83befa223ef98c52aef40cbe" +checksum = "1df8c4ec4b0627e53bdf214615ad287367e482558cf84b109250b37464dc03ae" [[package]] name = "png" @@ -2152,9 +2172,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.36" +version = "1.0.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7342d5883fbccae1cc37a2353b09c87c9b0f3afd73f5fb9bba687a1f733b029" +checksum = "9027b48e9d4c9175fa2218adf3557f91c1137021739951d4932f5f8268ac48aa" dependencies = [ "unicode-xid", ] @@ -2167,9 +2187,9 @@ checksum = "9145ac0af1d93c638c98c40cf7d25665f427b2a44ad0a99b1dccf3e2f25bb987" [[package]] name = "quote" -version = "1.0.16" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4af2ec4714533fcdf07e886f17025ace8b997b9ce51204ee69b6da831c3da57" +checksum = "a1feb54ed693b93a84e14094943b84b7c4eae204c512b7ccb95ab0c66d278ad1" dependencies = [ "proc-macro2", ] @@ -2233,7 +2253,7 @@ version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7" dependencies = [ - "getrandom 0.2.5", + "getrandom 0.2.6", ] [[package]] @@ -2262,9 +2282,9 @@ checksum = "63e935c45e09cc6dcf00d2f0b2d630a58f4095320223d47fc68918722f0538b6" [[package]] name = "rapier3d" -version = "0.12.0-alpha.1" +version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f0590e74514004c7313934d092ed071302146323124efde9d30d6aa517186bf" +checksum = "652dc538f3b0b0c1ba75aa3f4bdcac8d5132630bce22efd54a7240bdac33108d" dependencies = [ "approx", "arrayvec", @@ -2284,9 +2304,9 @@ dependencies = [ [[package]] name = "raw-window-handle" -version = "0.4.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fba75eee94a9d5273a68c9e1e105d9cffe1ef700532325788389e5a83e2522b7" +checksum = "b800beb9b6e7d2df1fe337c9e3d04e3af22a124460fb4c30fcc22c9117cefb41" dependencies = [ "cty", ] @@ -2305,9 +2325,9 @@ checksum = "a0d463f2884048e7153449a55166f91028d5b0ea53c79377099ce4e8cf0cf9bb" [[package]] name = "redox_syscall" -version = "0.2.12" +version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ae183fc1b06c149f0c1793e1eb447c8b04bfe46d48e9e48bfb8d2d7ed64ecf0" +checksum = "62f25bc4c7e55e0b0b7a1d43fb893f4fa1361d0abe38b9ce4f323c2adfe6ef42" dependencies = [ "bitflags", ] @@ -2344,6 +2364,12 @@ version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f1382d1f0a252c4bf97dc20d979a2fdd05b024acd7c2ed0f7595d7817666a157" +[[package]] +name = "robust" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5864e7ef1a6b7bcf1d6ca3f655e65e724ed3b52546a0d0a663c991522f552ea" + [[package]] name = "ron" version = "0.7.0" @@ -2425,18 +2451,18 @@ checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" [[package]] name = "serde" -version = "1.0.136" +version = "1.0.137" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce31e24b01e1e524df96f1c2fdd054405f8d7376249a5110886fb4b658484789" +checksum = "61ea8d54c77f8315140a05f4c7237403bf38b72704d031543aa1d16abbf517d1" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.136" +version = "1.0.137" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08597e7152fcd306f41838ed3e37be9eaeed2b61c42e2117266a554fab4662f9" +checksum = "1f26faba0c3959972377d3b2d306ee9f71faee9714294e41bb777f83f88578be" dependencies = [ "proc-macro2", "quote", @@ -2445,9 +2471,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.79" +version = "1.0.81" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e8d9fa5c3b304765ce1fd9c4c8a3de2c8db365a5b91be52f186efc675681d95" +checksum = "9b7ce2b32a1aed03c558dc61a5cd328f15aff2dbc17daad8fb8af04d2100e15c" dependencies = [ "itoa", "ryu", @@ -2494,9 +2520,9 @@ dependencies = [ [[package]] name = "slab" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9def91fd1e018fe007022791f865d0ccc9b3a0d5001e01aabb8b40e46000afb5" +checksum = "eb703cfe953bccee95685111adeedb76fabe4e97549a58d16f03ea7b9367bb32" [[package]] name = "slotmap" @@ -2516,6 +2542,18 @@ dependencies = [ "serde", ] +[[package]] +name = "spade" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "333b8c21ebd9a45c5e955f3d7a1f0c4a2214847dd7e8e1abb69f34ec9b88882d" +dependencies = [ + "num-traits", + "optional", + "robust", + "smallvec", +] + [[package]] name = "spirv" version = "0.2.0+1.5.4" @@ -2601,9 +2639,9 @@ checksum = "8fb1df15f412ee2e9dfc1c504260fa695c1c3f10fe9f4a6ee2d2184d7d6450e2" [[package]] name = "syn" -version = "1.0.89" +version = "1.0.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea297be220d52398dcc07ce15a209fce436d361735ac1db700cab3b6cdfb9f54" +checksum = "7ff7c592601f11445996a06f8ad0c27f094a58857c2f89e97974ab9235b92c52" dependencies = [ "proc-macro2", "quote", @@ -2621,18 +2659,18 @@ dependencies = [ [[package]] name = "thiserror" -version = "1.0.30" +version = "1.0.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "854babe52e4df1653706b98fcfc05843010039b406875930a70e4d9644e5c417" +checksum = "bd829fe32373d27f76265620b5309d0340cb8550f523c1dda251d6298069069a" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.30" +version = "1.0.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa32fd3f627f367fe16f893e2597ae3c05020f8bba2666a4e6ea73d377e5714b" +checksum = "0396bc89e626244658bef819e22d0cc459e795a5ebe878e6ec336d1674a8d79a" dependencies = [ "proc-macro2", "quote", @@ -2650,9 +2688,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.5.8" +version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a31142970826733df8241ef35dc040ef98c679ab14d7c3e54d827099b3acecaa" +checksum = "8d82e1a7758622a465f8cee077614c73484dac5b836c02ff6a40d5d1010324d7" dependencies = [ "indexmap", "serde", @@ -2660,9 +2698,9 @@ dependencies = [ [[package]] name = "tracing" -version = "0.1.32" +version = "0.1.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a1bdf54a7c28a2bbf701e1d2233f6c77f473486b94bee4f9678da5a148dca7f" +checksum = "5d0ecdcb44a79f0fe9844f0c4f33a342cbcbb5117de8001e6ba0dc2351327d09" dependencies = [ "cfg-if 1.0.0", "pin-project-lite", @@ -2672,9 +2710,9 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.20" +version = "0.1.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e65ce065b4b5c53e73bb28912318cb8c9e9ad3921f1d669eb0e68b4c8143a2b" +checksum = "cc6b8ad3567499f98a1db7a752b07a7c8c7c7c34c332ec00effb2b0027974b7c" dependencies = [ "proc-macro2", "quote", @@ -2683,9 +2721,9 @@ dependencies = [ [[package]] name = "tracing-core" -version = "0.1.23" +version = "0.1.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa31669fa42c09c34d94d8165dd2012e8ff3c66aca50f3bb226b68f216f2706c" +checksum = "f54c8ca710e81886d498c2fd3331b56c93aa248d49de2222ad2742247c60072f" dependencies = [ "lazy_static", "valuable", @@ -2693,9 +2731,9 @@ dependencies = [ [[package]] name = "tracing-log" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6923477a48e41c1951f1999ef8bb5a3023eb723ceadafe78ffb65dc366761e3" +checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" dependencies = [ "lazy_static", "log", @@ -2704,9 +2742,9 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.9" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e0ab7bdc962035a87fba73f3acca9b8a8d0034c2e6f60b84aeaaddddc155dce" +checksum = "4bc28f93baff38037f64e6f43d34cfa1605f27a49c34e8a04c5e78b0babf2596" dependencies = [ "ansi_term", "lazy_static", @@ -2751,9 +2789,9 @@ checksum = "3ed742d4ea2bd1176e236172c8429aaf54486e7ac098db29ffe6529e0ce50973" [[package]] name = "unicode-xid" -version = "0.2.2" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ccb82d61f80a663efe1f787a51b16b5a51e3314d6ac365b08639f52387b33f3" +checksum = "957e51f3646910546462e67d5f7599b9e4fb8acdd304b087a6494730f9eebf04" [[package]] name = "uuid" @@ -2761,7 +2799,7 @@ version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" dependencies = [ - "getrandom 0.2.5", + "getrandom 0.2.6", "serde", ] @@ -2809,9 +2847,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.79" +version = "0.2.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25f1af7423d8588a3d840681122e72e6a24ddbcb3f0ec385cac0d12d24256c06" +checksum = "27370197c907c55e3f1a9fbe26f44e937fe6451368324e009cba39e139dc08ad" dependencies = [ "cfg-if 1.0.0", "wasm-bindgen-macro", @@ -2819,9 +2857,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.79" +version = "0.2.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b21c0df030f5a177f3cba22e9bc4322695ec43e7257d865302900290bcdedca" +checksum = "53e04185bfa3a779273da532f5025e33398409573f348985af9a1cbf3774d3f4" dependencies = [ "bumpalo", "lazy_static", @@ -2834,9 +2872,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-futures" -version = "0.4.29" +version = "0.4.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2eb6ec270a31b1d3c7e266b999739109abce8b6c87e4b31fcfcd788b65267395" +checksum = "6f741de44b75e14c35df886aff5f1eb73aa114fa5d4d00dcd37b5e01259bf3b2" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -2846,9 +2884,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.79" +version = "0.2.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f4203d69e40a52ee523b2529a773d5ffc1dc0071801c87b3d270b471b80ed01" +checksum = "17cae7ff784d7e83a2fe7611cfe766ecf034111b49deb850a3dc7699c08251f5" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -2856,9 +2894,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.79" +version = "0.2.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa8a30d46208db204854cadbb5d4baf5fcf8071ba5bf48190c3e59937962ebc" +checksum = "99ec0dc7a4756fffc231aab1b9f2f578d23cd391390ab27f952ae0c9b3ece20b" dependencies = [ "proc-macro2", "quote", @@ -2869,15 +2907,15 @@ dependencies = [ [[package]] name = "wasm-bindgen-shared" -version = "0.2.79" +version = "0.2.80" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d958d035c4438e28c70e4321a2911302f10135ce78a9c7834c0cab4123d06a2" +checksum = "d554b7f530dee5964d9a9468d95c1f8b8acae4f282807e7d27d4b03099a46744" [[package]] name = "web-sys" -version = "0.3.56" +version = "0.3.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c060b319f29dd25724f09a2ba1418f142f539b2be99fbf4d2d5a8f7330afb8eb" +checksum = "7b17e741662c70c8bd24ac5c5b18de314a2c26c32bf8346ee1e6f53de919c283" dependencies = [ "js-sys", "wasm-bindgen", @@ -2929,9 +2967,9 @@ dependencies = [ [[package]] name = "wgpu-hal" -version = "0.12.4" +version = "0.12.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93b1a9400e8d7f32dd4dd909bb9a391015d70633d639775ddd3f14d1104bc970" +checksum = "d684ea6a34974a2fc19f1dfd183d11a62e22d75c4f187a574bb1224df8e056c2" dependencies = [ "arrayvec", "ash", diff --git a/Cargo.toml b/Cargo.toml index 55ffb65..96cf7cb 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" [dependencies] rand = "0.8" -bevy_polyline = "*" +bevy_polyline = "0.2" noise = { git = "https://github.com/Razaekel/noise-rs" } hexasphere = "7" wgpu = "0.12" @@ -14,7 +14,7 @@ wgpu = "0.12" debug_render = [] [dependencies.bevy] -version = "0.6" +version = "0.7" default-features = false features = [ "bevy_gilrs", @@ -26,11 +26,8 @@ features = [ ] [dependencies.bevy_rapier3d] -#git = "https://github.com/nebkor/bevy_rapier" -#path = "../bevy_rapier/bevy_rapier3d" -#branch = "debug-render-capsule" features = ["simd-nightly"] -version = "0.12" +version = "0.13" # Maybe also enable only a small amount of optimization for our code: [profile.dev] diff --git a/src/action.rs b/src/action.rs index a84a288..7645d1e 100644 --- a/src/action.rs +++ b/src/action.rs @@ -1,5 +1,7 @@ use bevy::prelude::*; -use bevy_rapier3d::{na::Vector3, prelude::*}; +use bevy_rapier3d::prelude::{ + ExternalForce, Friction, NoUserData, RapierConfiguration, RapierPhysicsPlugin, Velocity, +}; use crate::{ bike::{CyberBikeBody, CyberBikeCollider, CyberBikeControl}, @@ -28,14 +30,14 @@ fn gravity( mut config: ResMut, ) { let gravity = xform.single().translation.normalize() * -settings.gravity; - config.gravity = gravity.into(); + config.gravity = gravity; } fn falling_cat_pid( mut bike_query: Query<( &Transform, - &RigidBodyVelocityComponent, - &mut RigidBodyForcesComponent, + &Velocity, + &mut ExternalForce, &mut CyberBikeControl, )>, ) { @@ -105,19 +107,14 @@ fn falling_cat_pid( } } - forces.torque = torque.into(); + forces.torque = torque; } -fn drag( - mut query: Query< - (&RigidBodyVelocityComponent, &mut RigidBodyForcesComponent), - With, - >, -) { +fn drag(mut query: Query<(&Velocity, &mut ExternalForce), With>) { let (vels, mut forces) = query.single_mut(); - if let Some(vel) = vels.linvel.try_normalize(0.001) { - let v2 = vels.linvel.magnitude_squared(); + if let Some(vel) = vels.linvel.try_normalize() { + let v2 = vels.linvel.length_squared(); forces.force -= vel * v2 * 0.02; } } @@ -125,21 +122,21 @@ fn drag( fn input_forces( settings: Res, input: Res, - mut cquery: Query<&mut ColliderMaterialComponent, With>, - mut bquery: Query<(&Transform, &mut RigidBodyForcesComponent), With>, + mut cquery: Query<&mut Friction, With>, + mut bquery: Query<(&Transform, &mut ExternalForce), With>, ) { let (xform, mut forces) = bquery.single_mut(); - let mut cmat = cquery.single_mut(); + let mut friction = cquery.single_mut(); // thrust - let thrust: Vector3 = (xform.forward() * input.throttle * settings.accel).into(); + let thrust = xform.forward() * input.throttle * settings.accel; forces.force += thrust; // brake - cmat.friction = if input.brake { 2.0 } else { 0.0 }; + friction.coefficient = if input.brake { 2.0 } else { 0.0 }; // steering - let torque: Vector3 = (xform.up() * input.yaw * settings.sensitivity).into(); + let torque = xform.up() * input.yaw * settings.sensitivity; forces.torque += torque; } diff --git a/src/bike.rs b/src/bike.rs index bd8410a..6e9c428 100644 --- a/src/bike.rs +++ b/src/bike.rs @@ -22,65 +22,60 @@ pub struct CyberBikeControl { pub prev_pitch_error: f32, } -const BIKE_BODY_GROUP: InteractionGroups = InteractionGroups::new(0b01, 0b01); -const BIKE_WHEEL_GROUP: InteractionGroups = InteractionGroups::new(0b10, 0b10); +const BIKE_BODY_COLLISION_GROUP: (u32, u32) = (0b01, 0b01); +const BIKE_WHEEL_COLLISION_GROUP: (u32, u32) = (0b10, 0b10); fn spawn_cyberbike(mut commands: Commands, asset_server: Res) { let xform = Transform::from_translation(Vec3::X * SPAWN_ALTITUDE) .with_rotation(Quat::from_axis_angle(Vec3::Z, -89.0f32.to_radians())); - let mut bbody = RigidBodyBundle::default(); + let damping = Damping { + angular_damping: 0.5, + linear_damping: 0.1, + }; + let not_sleeping = Sleeping::disabled(); - bbody.damping.angular_damping = 0.5; - bbody.damping.linear_damping = 0.1; - bbody.activation = RigidBodyActivation::cannot_sleep().into(); + let ccd = Ccd { enabled: true }; - bbody.ccd = RigidBodyCcd { - ccd_enabled: true, - ccd_thickness: 0.2, - ccd_max_dist: 2.7, - ..Default::default() - } - .into(); + let bcollider_shape = + Collider::capsule(Vec3::new(0.0, 0.0, -2.7), Vec3::new(0.0, 0.0, 2.5), 1.0); - let isometry = Isometry::from_parts(xform.translation.into(), xform.rotation.into()); - bbody.position = isometry.into(); - - let shape = ColliderShape::capsule( - Vec3::new(0.0, 0.0, -2.7).into(), - Vec3::new(0.0, 0.0, 2.5).into(), - 1.0, - ); - let bcollide = ColliderBundle { - shape: shape.into(), - mass_properties: ColliderMassProps::Density(0.2).into(), - flags: ColliderFlags { - collision_groups: BIKE_BODY_GROUP, - ..Default::default() - } - .into(), - material: ColliderMaterial { - friction: 0.0, - restitution: 0.0, - ..Default::default() - } - .into(), + let friction = Friction { + coefficient: 0.0, ..Default::default() }; + let restitution = Restitution { + coefficient: 0.0, + ..Default::default() + }; + + let mass_properties = ColliderMassProperties::Density(0.2); + + let (membership, filter) = BIKE_BODY_COLLISION_GROUP; + let bike_collision_group = CollisionGroups::new(membership, filter); + let bike = commands - .spawn_bundle(bbody) + .spawn() + .insert(RigidBody::Dynamic) .insert_bundle((xform, GlobalTransform::default())) - .insert(RigidBodyPositionSync::Interpolated { prev_pos: None }) - .with_children(|child_builder| { - child_builder - .spawn_bundle(bcollide) - .insert(ColliderDebugRender { - color: Color::GREEN, - }) - .insert(CyberBikeCollider) - .insert(ColliderPositionSync::Discrete); + .insert_bundle(( + bcollider_shape, + bike_collision_group, + mass_properties, + damping, + restitution, + friction, + not_sleeping, + ccd, + )) + .insert(TransformInterpolation { + start: None, + end: None, }) + .insert(Velocity::zero()) + .insert(ExternalForce::default()) + .insert(CyberBikeCollider) .with_children(|rider| { rider.spawn_scene(asset_server.load("cyber-bike_no_y_up.glb#Scene0")); }) @@ -93,6 +88,10 @@ fn spawn_cyberbike(mut commands: Commands, asset_server: Res) { let wheel_positions = vec![-5.1, 4.7, -5.1]; let wheel_y = -1.8f32; + // re-set the collision group + let (membership, filter) = BIKE_WHEEL_COLLISION_GROUP; + let wheels_collision_group = CollisionGroups::new(membership, filter); + for (i, &wheel_z) in wheel_positions.iter().enumerate() { let (wheel_x, wheel_rad, stiffness) = match i { 0 => (-2.6, 1.0, 0.016), @@ -102,47 +101,34 @@ fn spawn_cyberbike(mut commands: Commands, asset_server: Res) { }; let offset = Vec3::new(wheel_x, wheel_y, wheel_z); let trans = xform.translation + offset; - let wheel_pos_in_world = Isometry::from_parts(trans.into(), xform.rotation.into()); - let _wheel_rb = commands - .spawn_bundle(RigidBodyBundle { - position: wheel_pos_in_world.into(), - activation: RigidBodyActivation::cannot_sleep().into(), - damping: RigidBodyDamping { - angular_damping: 0.8, - ..Default::default() - } - .into(), - ccd: RigidBodyCcd { - ccd_enabled: true, - ccd_max_dist: wheel_rad, - ccd_thickness: 0.01, - ..Default::default() - } - .into(), - ..Default::default() - }) - .insert_bundle(ColliderBundle { - material: ColliderMaterial::new(0.0, 0.0).into(), - shape: ColliderShape::ball(wheel_rad).into(), - mass_properties: ColliderMassProps::Density(0.001).into(), - flags: ColliderFlags { - collision_groups: BIKE_WHEEL_GROUP, - ..Default::default() - } - .into(), - ..Default::default() - }) - .insert(ColliderPositionSync::Discrete) - .insert(ColliderDebugRender::from(Color::YELLOW)) - .id(); + let wheel_pos_in_world = Transform::from_rotation(xform.rotation).with_translation(trans); + let wheel_damping = Damping { + angular_damping: 0.8, + ..Default::default() + }; + let wheel_collider = Collider::ball(wheel_rad); + let mass_props = ColliderMassProperties::Density(0.001); let damping = 0.3; - - let prismatic = PrismaticJoint::new(Vector::y_axis()) - .local_anchor1(offset.into()) + let prismatic = PrismaticJointBuilder::new(Vec3::Y) + .local_anchor1(offset) .motor_position(-0.4, stiffness, damping); + let joint = ImpulseJoint::new(bike, prismatic); - commands.spawn_bundle(((JointBuilderComponent::new(prismatic, bike, _wheel_rb)),)); + let _wheel_rb = commands + .spawn() + .insert(RigidBody::Dynamic) + .insert_bundle((wheel_pos_in_world, GlobalTransform::default())) + .insert_bundle(( + wheel_collider, + mass_props, + wheel_damping, + ccd, + not_sleeping, + joint, + wheels_collision_group, + )) + .id(); } } @@ -150,7 +136,7 @@ pub struct CyberBikePlugin; impl Plugin for CyberBikePlugin { #[cfg(feature = "debug_render")] fn build(&self, app: &mut App) { - app.add_plugin(RapierRenderPlugin) + app.add_plugin(RapierDebugRenderPlugin::default()) .add_startup_system_to_stage(StartupStage::PostStartup, spawn_cyberbike); } diff --git a/src/camera.rs b/src/camera.rs index 86c1c3c..9448a53 100644 --- a/src/camera.rs +++ b/src/camera.rs @@ -1,6 +1,9 @@ use bevy::{ - prelude::*, - render::camera::{ActiveCameras, Camera, CameraPlugin}, + prelude::{ + info, Commands, Component, Entity, Input, KeyCode, ParamSet, PerspectiveCameraBundle, + PerspectiveProjection, Plugin, Quat, Query, Res, ResMut, State, Transform, With, + }, + render::camera::{ActiveCamera, Camera3d}, }; use crate::{bike::CyberBikeModel, input::InputState}; @@ -36,23 +39,23 @@ fn setup_cybercams(mut commands: Commands) { .insert(CyberCameras::Hero); commands - .spawn_bundle(PerspectiveCameraBundle::with_name("Inactive")) + .spawn_bundle(PerspectiveCameraBundle::default()) .insert(CyberCameras::Debug); } fn follow_cyberbike( - mut query: QuerySet<( + mut query: ParamSet<( // 0: the bike - QueryState<&Transform, With>, + Query<&Transform, With>, // 1: the cameras - QueryState<(&mut Transform, &CyberCameras)>, + Query<(&mut Transform, &CyberCameras)>, )>, input: Res, ) { - let bike_xform = *query.q0().single(); + let bike_xform = *query.p0().single(); let up = bike_xform.translation.normalize(); - for (mut cam_xform, cam_type) in query.q1().iter_mut() { + for (mut cam_xform, cam_type) in query.p1().iter_mut() { match *cam_type { CyberCameras::Hero => { let look_at = bike_xform.translation + (bike_xform.forward() * 200.0); @@ -79,26 +82,17 @@ fn follow_cyberbike( } fn update_active_camera( - mut active_cams: ResMut, + mut active_cams: ResMut>, state: Res>, - mut query: Query<(&mut Camera, &CyberCameras)>, + mut query: Query<(&CyberCameras, Entity)>, ) { - active_cams.remove(CameraPlugin::CAMERA_3D); - - // set all cameras to inactive - for (mut cam, _) in query.iter_mut() { - cam.name = Some("Inactive".to_string()); - } - - // find the camera with the current state, set its name to be active - for (mut cam, _) in query + // find the camera with the current state, set it as the ActiveCamera + query .iter_mut() - .filter(|(_, cybercam)| state.current().eq(cybercam)) - { - cam.name = Some(CameraPlugin::CAMERA_3D.to_string()); - } - - active_cams.add(CameraPlugin::CAMERA_3D); + .filter(|(cybercam, _)| state.current().eq(cybercam)) + .for_each(|(_, entity)| { + active_cams.set(entity); + }); } fn cycle_cam_state(mut state: ResMut>, mut keys: ResMut>) { diff --git a/src/glamor.rs b/src/glamor.rs index ee47042..1f1863e 100644 --- a/src/glamor.rs +++ b/src/glamor.rs @@ -2,7 +2,7 @@ use bevy::{ prelude::*, render::mesh::{Indices, VertexAttributeValues}, }; -use bevy_polyline::{Polyline, PolylineBundle, PolylineMaterial, PolylinePlugin}; +use bevy_polyline::prelude::{Polyline, PolylineBundle, PolylineMaterial, PolylinePlugin}; use rand::{thread_rng, Rng}; use crate::{lights::AnimateCyberLightWireframe, planet::CyberPlanet}; diff --git a/src/input.rs b/src/input.rs index 3d4ad18..e67e99f 100644 --- a/src/input.rs +++ b/src/input.rs @@ -1,5 +1,5 @@ use bevy::{ - app::{Events, ManualEventReader}, + ecs::event::{Events, ManualEventReader}, prelude::*, }; @@ -13,33 +13,42 @@ pub(crate) struct InputState { } fn update_input(events: Res>, mut istate: ResMut) { + let mut throttle = 0.0; + let mut brake = false; + let mut pitch = 0.0; + let mut yaw = 0.0; for GamepadEvent(_, ev) in istate.event_reader.iter(&events) { match *ev { GamepadEventType::ButtonChanged(GamepadButtonType::RightTrigger2, val) => { - istate.throttle = val; + throttle += val; } GamepadEventType::ButtonChanged(GamepadButtonType::LeftTrigger2, val) => { - istate.throttle = -val; + throttle -= val; } GamepadEventType::ButtonChanged(GamepadButtonType::East, val) => { if val > 0.5 { - istate.brake = true; + brake = true; } else { - istate.brake = false; + brake = false; } } GamepadEventType::AxisChanged(GamepadAxisType::LeftStickX, val) => { - istate.yaw = -val; + yaw -= val; } // ignore spurious vertical movement for now GamepadEventType::AxisChanged(GamepadAxisType::LeftStickY, val) => { - istate.pitch = val; + pitch += val; } _ => { info!("unhandled gamepad event: {:?}", ev); } } } + + istate.throttle = throttle; + istate.brake = brake; + istate.pitch = pitch; + istate.yaw = yaw; } pub struct CyberInputPlugin; diff --git a/src/planet.rs b/src/planet.rs index 077deb6..69f2272 100644 --- a/src/planet.rs +++ b/src/planet.rs @@ -27,28 +27,16 @@ fn spawn_planet( let (mesh, shape) = gen_planet(isphere); - let pbody = RigidBodyBundle { - body_type: RigidBodyType::Static.into(), - ccd: RigidBodyCcd { - ccd_enabled: true, - ccd_thickness: 0.5, - ccd_max_dist: PLANET_RADIUS * 1.05, - ..Default::default() - } - .into(), - ..Default::default() - }; + let pbody = (RigidBody::Fixed, Ccd { enabled: true }); - let pcollide = ColliderBundle { - shape: shape.into(), - material: ColliderMaterial { - friction: 0.05, - restitution: 0.00, + let pcollide = ( + shape, + Friction { + coefficient: 0.05, ..Default::default() - } - .into(), - ..Default::default() - }; + }, + Restitution::new(0.0), + ); commands .spawn_bundle(PbrBundle { @@ -79,7 +67,7 @@ impl Plugin for CyberPlanetPlugin { // utils //--------------------------------------------------------------------- -fn gen_planet(sphere: Icosphere) -> (Mesh, ColliderShape) { +fn gen_planet(sphere: Icosphere) -> (Mesh, Collider) { // straight-up stolen from Bevy's impl of Mesh from Icosphere, so I can do the // displacement before normals are calculated. let generated = IcoSphere::new(sphere.subdivisions, |point| { @@ -122,13 +110,13 @@ fn gen_planet(sphere: Icosphere) -> (Mesh, ColliderShape) { idxs.push([idx[0], idx[1], idx[2]]); } - let shape = ColliderShape::trimesh(points.iter().map(|p| Point::from_slice(p)).collect(), idxs); + let shape = Collider::trimesh(points.iter().map(|p| Vect::from_slice(p)).collect(), idxs); let indices = Indices::U32(indices); let mut mesh = Mesh::new(PrimitiveTopology::TriangleList); mesh.set_indices(Some(indices)); - mesh.set_attribute(Mesh::ATTRIBUTE_POSITION, points); - mesh.set_attribute(Mesh::ATTRIBUTE_UV_0, uvs); + mesh.insert_attribute(Mesh::ATTRIBUTE_POSITION, points); + mesh.insert_attribute(Mesh::ATTRIBUTE_UV_0, uvs); (mesh, shape) } diff --git a/src/ui.rs b/src/ui.rs index 6292c9f..781cd50 100644 --- a/src/ui.rs +++ b/src/ui.rs @@ -34,12 +34,12 @@ fn setup_ui(mut commands: Commands, asset_server: Res) { } fn update_ui( - state_query: Query<&RigidBodyVelocityComponent, With>, + state_query: Query<&Velocity, With>, mut text_query: Query<&mut Text, With>, ) { let mut text = text_query.single_mut(); let state = state_query.single(); - text.sections[0].value = format!("spd: {:.2}", state.linvel.magnitude()); + text.sections[0].value = format!("spd: {:.2}", state.linvel.length()); } pub struct CyberUIPlugin;