Commit graph

56 commits

Author SHA1 Message Date
mat
6eee543a33
Pathfinder (#25)
Pathfinding is very much not done, but it works enough and I want to get this merged.
TODO: fast replanning, goals that aren't a single node, falling moves (it should be able to play the dropper), parkour moves
2022-11-12 23:54:05 -06:00
Ubuntu
ad8b1b7b24 ignore bad utf8 2022-11-09 18:59:03 +00:00
mat
44ab1ad6ef chore: Release 2022-10-30 14:04:11 -05:00
mat
889f742696 add "repository" field to all crates 2022-10-30 14:03:13 -05:00
mat
9de6c03dfb use variables directly in format strings
thanks clippy we love you
2022-10-27 21:22:47 -05:00
Ubuntu
924a4771d9 (cargo-release) version 0.2.0 2022-10-17 16:28:52 +00:00
Ubuntu
46fbc4654c (cargo-release) version 0.2.0 2022-10-17 16:28:51 +00:00
mat
98224cf913 fix clippy warnings 2022-10-15 16:53:34 -05:00
mat
6f6289376a fix errors with rewritten packet reading
i forgot i never tested it before LMAO
2022-10-07 23:56:23 -05:00
mat
bc3aa9467a
Replace impl Read with Cursor<&[u8]> (#26)
* Start getting rid of Cursor

* try to make the tests pass and fail

* make the tests pass

* remove unused uses

* fix clippy warnings

* fix potential OOM exploits

* fix OOM in az-nbt

* fix nbt benchmark

* fix a test

* start replacing it with Cursor<Vec<u8>>

* wip

* fix all the issues

* fix all tests

* fix nbt benchmark

* fix warnings
2022-10-07 20:12:36 -05:00
Ubuntu
f7e761dfd3 re-enable nbt benches 2022-09-14 18:33:51 +00:00
mat
0085f8a565 make some stuff publishable on crates.io 2022-08-30 21:42:40 -05:00
mat
f42d630544
Physics (#11)
* Put physics module in azalea-entity

* port aabb

* add more stuff to PositionXYZ

* azalea-physics

* important collision things

* more physics stuff

* backup because i'm about to delete shapes

* more shape stuff

* CubeVoxelShape

* no compile errors???

insane

* impl VoxelShape for ArrayVoxelShape

* Shapes stuff

* collide_x but it doesn't work yet

* binary_search

* it compiles

* Entity has bounding box

* Update discrete_voxel_shape.rs

* Entity::make_bounding_box

* ok i'm about to merge az-entity and az-world

might be a terrible idea which is why i'm committing first

* ok so i moved entity to world

* on_pos and move_entity compiles

* add send_position

* move collision stuff to collision module in az-physics

* dimension is no longer an Option

* start trying to do collision for the client

* collision works 🎉

* start adding palette resizing

* get_and_set (pain)

* it compiles but probably won't work

* add a test

* remove printlns

* add more tests for palette stuff

* ClientboundMoveVec3Packet -> ClientboundMoveEntityPosPacket

i think i changed this on accident once

* palette resizing works

todo: remove the printlns

* Remove printlns in palette.rs

* fix issues from merge

* fixes + work a bit more on physics

* Better entities (#19)

* well it compiles

* add tests to entity storage

* add suggestions in azalea-brigadier

* this probably causes ub

* fix brigadiersuggestions

* get rid of entityid

* test From<EntityMut> for EntityRef

* don't mention other libraries since there's too many

* fix warnings

* do todos in brigadier suggestions

* work on physics

* more physics stuff

* remove trait feature on az-block

i think rust gets confused and compiles the macro without the feature

* bump ahash

* aes tests in az-crypto

* optimize aes's deps

* fix crashes

* fix section_index for negative numbers and test

* fix BlockPos protocol implementation

* remove some debug prints

* prepare to add ai_step

* make ai step work

* clippy
2022-08-29 20:41:01 -05:00
mat
029ae0e567 use unsigned integers for nbt lengths
probably not an optimization, just makes more sense
2022-08-24 21:09:17 -05:00
mat
c64f10605b fix 2022-08-24 21:03:05 -05:00
mat
e33d57e767 optimize nbt bytearray 2022-08-24 21:02:11 -05:00
mat
2a2e82efeb make some code more idiomatic 2022-08-24 20:00:44 -05:00
mat
ac4d675d44
NBT decoder optimizations (#17)
* replace HashMap with AHashMap

* faster read_string by just doing read_exact

* re-enable all the benchmarks
2022-08-19 14:14:08 -05:00
mat
5a9fca0ca9
Better errors (#14)
* make reading use thiserror

* finish implementing all the error things

* clippy warnings related to ok_or

* fix some errors in other places

* thiserror in more places

* don't use closures in a couple places

* errors in writing packet

* rip backtraces

* change some BufReadError::Custom to UnexpectedEnumVariant

* Errors say what packet is bad

* error on leftover data and fix

it wasn't reading the properties for gameprofile
2022-08-06 02:22:19 -05:00
mat
cd9a05e5a6 read_into -> read_from
yeah
2022-06-25 02:33:28 -05:00
mat
ba399c4440 switch things to use azalea-buf 2022-06-23 15:28:33 -05:00
mat
5ca49e680e azalea-buf 2022-06-23 15:12:17 -05:00
mat
0530c57579 Fixes 2022-05-26 17:55:07 -05:00
mat
c987812927 clippy 2022-05-03 18:20:24 +00:00
mat
0bd798045c more azalea-world stuff 2022-05-03 00:33:32 -05:00
mat
db2fcecdc3 Change some generics to impl Trait 2022-05-01 22:58:20 -05:00
mat
44db8948d6 Re-enable NBT decoding benchmark 2022-05-01 22:53:24 -05:00
mat
567c6f4f2c Reduce usage of AsyncRead
We already receive everything from the server when it tells us the length, so we can actually just treat the stream as a Read instead of an AsyncRead.
2022-05-01 21:54:03 -05:00
mat
97d392f4e5 fix warnings in azalea-nbt 2022-04-24 14:56:46 -05:00
mat
59ef945094 fix writing wrong ids in nbt 2022-04-24 14:53:01 -05:00
mat
b43ad19636 remove an unused thing from dependencies 2022-04-24 14:44:02 -05:00
Ubuntu
7a272c216b Vec<Tag> to [Tag] 2022-04-23 04:28:19 +00:00
Ubuntu
46454793e0 clean up some code 2022-04-23 04:14:19 +00:00
mat
3a6810ca1d vroom vroom 2022-04-22 22:38:42 -05:00
mat
3057ae8b4a maybe optimization 2022-04-22 20:49:42 -05:00
mat
b03d3da659 inline reading in nbt decoding 2022-04-22 18:23:29 +00:00
mat
99652200aa simplify nbt list optimization 2022-04-22 18:03:57 +00:00
mat
7df6522489 remove irrelevant comment 2022-04-22 14:51:03 +00:00
mat
67c6e33344 fix nbt decode benchmark 2022-04-22 00:52:22 -05:00
mat
1bbd8b99b3 nbt optimizations 2022-04-22 05:02:45 +00:00
mat
39d77475d3 remove some useless code 2022-04-22 04:37:45 +00:00
mat
248f752748 simplify error handling 2022-04-22 04:33:58 +00:00
mat
03d14e13f2 make benchmarks work again 2022-04-21 18:08:33 +00:00
mat
3beb58189b tokio features in az-nbt 2022-04-21 17:24:20 +00:00
mat
af28b0e57a reading nbt in the protocol works 2021-12-26 14:15:06 -06:00
mat
1cdd061a99 ok i give up remove the async benchmarks 2021-12-25 15:10:08 -06:00
mat
6ae94b96e6 start adding nbt to the protocol 2021-12-20 15:22:02 -06:00
mat
cf88c7b795 add some things to readmes 2021-12-20 13:36:20 -06:00
mat
b91b579bef add more tests and benchmarks for nbt 2021-12-20 01:53:23 -06:00
mat
5090ebe25f slight nbt optimizations 2021-12-20 01:04:18 -06:00