Commit graph

7 commits

Author SHA1 Message Date
Ryan 69ba704352 Implement the block change packets 2022-06-22 08:06:54 -07:00
Ryan adc8a4faae Give World ownership over entities, clients, and chunks.
This change was made to make it easier for invariants to be upheld. When
the spatial partition is added, we can ensure that changes to entities
are immediately reflected in the partition. Additionally, chunks being
shared between worlds was a leaky abstraction to begin with and is now
removed. A method in `Config` is now necessary to determine what world a
client should join.

Along with this, most mutable references have been wrapped in a newtype
to ensure that `mem::swap` cannot be used on them, which would break
invariants. This is analogous to `Pin<&mut T>`. The reason we can't use
Pin directly is because it would require unnecessary unsafe code
within the library.
2022-05-16 02:36:14 -07:00
Ryan 732183dd62 Rip out the ECS. 2022-04-29 00:48:41 -07:00
Ryan 1a27cb92ce Expand block state API 2022-04-19 23:40:33 -07:00
Ryan 064dcfbc0b Get the block state generator to match what the client expects 2022-04-18 00:43:34 -07:00
Ryan b5a88be024 cargo fmt 2022-04-17 17:06:13 -07:00
Ryan a997820b7a Add block state generator 2022-04-17 17:04:39 -07:00