Commit Graph

441 Commits

Author SHA1 Message Date
kralverde
7347bae275 make commands async (#179) 2024-10-25 11:36:55 +02:00
Snowiiii
4bb52a7711 deny more clippy lints 2024-10-24 19:30:24 +02:00
Alvsch
7de3e0e995 Improved pvp (#173)
* Added CSoundEffect packet

* Added sound macro

added a macro that turns sound namespaces to the sounds id

* added CEntitySoundEffect

* updated id to i32

* Added sound effects to pvp

* Added sweeping and particles

* Added I-Frames to living entity

* Refactored combat

split up the combat handling into multiple functions and a new combat module

* use new packet macro

* updated json files

* fixed attacking

* use builtin clamp
2024-10-24 17:49:23 +02:00
lokka30
d78c02fa76 fix: autenticate -> authenticate (#175)
Fixed a typo in client_packets.rs.

I believe all references to the function (1 of them - on line 155) have
been renamed to reflect the corrected spelling.

I ran and joined the server with no problems after making this change.
2024-10-24 16:11:59 +02:00
Snowiiii
6fb751accf Update to 1.21.3 2024-10-23 19:41:08 +02:00
Snowiiii
14ff151d88 Move from ids to uuids 2024-10-23 16:38:30 +02:00
Alexander Medvedev
e396399e66 Port to 1.21.2 (#171)
* Update JSON Files to 1.21.2

* Update constants to 1.21.2

* Port c_login_success to 1.21.2

* Fix: damage type

* Overhaul Packet ID system

We now use Packet IDS from enums.

1. This is very very nice for seeing which Packets are already implemented and which not.
2. This lets us easly port to newer Minecraft version, In vanilla there are no Packet ids hardcoded, Packet IDs will be parsed from a enum like this

* Port all Packets to 1.20.2

* Update README badge to 1.20.2

* Change doc for the new packet id system
2024-10-23 14:31:23 +02:00
Snowiiii
91ae85efa5 Add new player to server list 2024-10-22 17:40:26 +02:00
Snowiiii
b8b4a8ce8d Make CommandSender not mut 2024-10-22 14:02:49 +02:00
kralverde
9eac0f01e1 Fix chunk loading deadlock and dangling chunk memory (#159)
* rebase to master

* fix chunk unloading
2024-10-22 13:15:17 +02:00
Snowiiii
f7398bf4db clippy: remove clippy::nursery lints
Like clippy doc says nursery means "new lints that are still under development", I like stable things
2024-10-22 11:46:19 +02:00
Snowiiii
790adbc0b3 Merge branch 'master' of https://github.com/Snowiiii/Pumpkin 2024-10-22 11:29:32 +02:00
kralverde
43116c54e9 fix tick system (#169)
* fix tick system

* also async wait on stdin
2024-10-22 11:27:40 +02:00
Edvin Bryntesson
b0009d1afe make not blocking 2024-10-21 22:29:29 +02:00
Edvin Bryntesson
e9e0bb7102 make buffer to chunks length 2024-10-21 22:29:29 +02:00
Edvin Bryntesson
f88ce46480 add get_block function 2024-10-21 22:29:29 +02:00
Edvin Bryntesson
4338bcff16 refactor things out into functions 2024-10-21 22:29:27 +02:00
Edvin Bryntesson
d7b162e68e remove unnecessary cloning 2024-10-21 22:28:28 +02:00
Edvin Bryntesson
843a1d7519 add block placing 2024-10-21 22:28:28 +02:00
Edvin Bryntesson
1e15f8b3ba implemented persistent block breaking 2024-10-21 22:28:26 +02:00
kralverde
60f1bb6195 More debug messages for packets (#156)
* rebase to master

* rebase to master

* rebase to master

* rebase to master

* add debug messages for chunk sender

* add more debug messages for chunk sender

* add more debug messages for chunk sender

* fix dead lock

* rebase to master

* revert fixs leaving only debug messages

* better logging
2024-10-21 21:06:50 +02:00
Snowiiii
287f466ae1 More workspace dependencies 2024-10-21 19:36:42 +02:00
AnonymousBit
112110272b Better logging (#167)
* feat: logs for when a player interacts with a block out of reach

* cleanup: used self.gameprofile instead of getting it from the client

* cleanup: better logging

* fix: added logging library

* cleanup:removed unused namespace

* cleanup: capitalisation and log levels

* fix: removed simple logging

* fix: removed todo! where not needed

* cleanup: removed duplicate dbg!

* Fix mistake in merging

* Fix my bad

* Merge repeated match arms
2024-10-21 18:36:19 +02:00
Snowiiii
3c57ef0a12 fix: cargo fmt :D 2024-10-21 15:19:15 +02:00
Snowiiii
6484daaf5b fix: clippy in release 2024-10-21 15:16:36 +02:00
Snowiiii
12ab2c7298 Clippy: warn clippy::pedantic 2024-10-21 15:07:05 +02:00
Stefano
c350348ee5 Prevent panic on client poll function 2024-10-21 14:01:36 +02:00
Snowiiii
bb050958a2 Add Tick system 2024-10-21 13:25:04 +02:00
Stefano
c95e61a2c6 Merge branch 'Snowiiii:master' into master 2024-10-20 23:48:51 +02:00
Snowiiii
655d02dc87 fix: cargo fmt 2024-10-20 23:29:50 +02:00
Snowiiii
8ede38d805 fix: knockback 2024-10-20 23:29:28 +02:00
Stefano
07da0db21f Fix formatting player.rs 2024-10-20 23:16:58 +02:00
Stefano
74e58caab1 Handle player packet id 0x23 2024-10-20 20:59:35 +02:00
Alvsch
0c0ca16bcc fixed player movement syncing 2024-10-20 15:41:08 +02:00
Alvsch
e9833a798c use profile before moving 2024-10-20 14:33:44 +02:00
Alvsch
6559b49f2f made encryption config work 2024-10-20 14:01:20 +02:00
kralverde
637104c57e add unload chunks too 2024-10-19 13:13:58 -04:00
kralverde
224242c793 rebase to master 2024-10-19 12:50:35 -04:00
Snowiiii
59d75d9f1e fix: clippy 2024-10-19 18:27:04 +02:00
Snowiiii
75e7b0a8e8 tokio: Support RCON 2024-10-19 18:12:06 +02:00
Snowiiii
2287564973 Merge branch 'master' into tokio 2024-10-19 17:52:33 +02:00
Alvsch
c85216242e Fixed cylindrical 2024-10-19 14:49:05 +02:00
Snowiiii
387da2c8b5 Fix: blocking 2024-10-19 13:53:41 +02:00
Snowiiii
a9f645488d Fix: Wrong polling logic 2024-10-19 11:41:25 +02:00
Snowiiii
2945a6542e Fix: Gamemode messages
Do not send them to target, send them to sender
2024-10-19 10:57:11 +02:00
Alexander Medvedev
9d558967c1 Merge pull request #143 from kralverde/icon
Fix server icons + add server icon to config
2024-10-18 21:59:47 +01:00
kralverde
086e347d3a rework favicon selection process 2024-10-18 16:53:49 -04:00
kralverde
6b7d6249de fix png encoding, default to ./icon.png, use built-in default 2024-10-18 15:58:12 -04:00
Snowiiii
5ac45b0ed5 Support parsing players out of commands and custom error messages 2024-10-18 20:30:14 +02:00
Snowiiii
406db91f06 Add Scoreboard support 2024-10-18 18:22:24 +02:00