Commit Graph

15223 Commits

Author SHA1 Message Date
Dylan K. Taylor
3ca80b353b InventoryTransactionEvent: rewrite documentation 2022-05-21 21:20:11 +01:00
Dylan K. Taylor
7d172e2211 PlayerCommandPreprocessEvent: updated documentation 2022-05-21 21:07:29 +01:00
Dylan K. Taylor
e934e2bd26 PlayerDropItemEvent: updated documentation
this can be triggered by dropping an item outside of the inventory menu while the inventory window is open.
2022-05-21 21:05:27 +01:00
Dylan K. Taylor
3177d19730 PlayerKickEvent: improved woefully inadequate documentation 2022-05-21 21:03:56 +01:00
Dylan K. Taylor
82104a8251 UpdateNotifyEvent: updated documentation 2022-05-21 20:32:30 +01:00
Dylan K. Taylor
e9a17374d1 Rewrite documentation of CommandEvent
no wonder people get the idea to use this shit for banning commands ...
2022-05-21 20:29:25 +01:00
Dylan K. Taylor
a31bd19b5a Deprecated PlayerCommandPreProcessEvent
to be removed in PM5

see #4284
2022-05-21 20:20:09 +01:00
Dylan K. Taylor
c82dfef9b0 Player: fix weird behaviour when teleporting sleeping players
closes #4672
2022-05-21 20:08:12 +01:00
Dylan K. Taylor
1181b13b5d Player: call InventoryCloseEvent after doing the necessary business
closes #4626

this does change the behaviour of getCurrentWindow() during InventoryCloseEvent, but no one should be using that anyway, since InventoryCloseEvent->getInventory() exists.
2022-05-21 19:23:59 +01:00
Dylan K. Taylor
688be0a404 Server: apply server.properties difficulty to newly generated worlds
see #5057

jury is out on whether or not this should override difficulty on preexisting worlds, but it's non-controversial that it should apply at least to newly generated worlds.
2022-05-21 18:46:38 +01:00
Dylan K. Taylor
33e6b63fe5 Explosion: remove unused local variable in explodeB() 2022-05-21 17:39:11 +01:00
Dylan K. Taylor
5d92eddc82 InventoryTransaction: provide object ID of failed action for debugging identification
closes #3235
2022-05-21 17:35:21 +01:00
Dylan K. Taylor
0324392cd8 Clean PHPStan baseline 2022-05-21 17:12:47 +01:00
Dylan K. Taylor
01b0742bd4 LightUpdate: account for virtual nodes in prepareNodes()
fixes #3959
2022-05-21 17:07:49 +01:00
TheNewHEROBRINEX
02cf6ae46c Added PlayerDeathEvent->setKeepXp(), closes #4002 (#4015) 2022-05-21 16:41:14 +01:00
Dylan K. Taylor
fcb2ccab99 NetworkSession: Sync all attributes on respawn 2022-05-21 16:22:35 +01:00
Dylan K. Taylor
a38a5c67f1 GiveCommand: show the search term in audit message, instead of the ID
this is more useful in the longer term.
2022-05-21 15:49:17 +01:00
Dylan K. Taylor
a45a96b3ee ShulkerBoxInventory: fixed inappropriate usage of BlockLegacyIds when comparing item IDS 2022-05-21 15:40:25 +01:00
Dylan K. Taylor
86efa0aae6 Merge remote-tracking branch 'origin/stable' into next-minor 2022-05-20 17:49:04 +01:00
Covered123
2b84cb7be4 DisablePluginException now can be used to disable plugins (#4780)
closes #2671
2022-05-20 17:01:34 +01:00
ipad54
26df37e6ef Minecart: fixed max stack size to match vanilla (#5051) 2022-05-20 16:57:48 +01:00
Dylan K. Taylor
554f96bc24 InventoryManager: Defer opening new windows to the client until the window close handshake has been completed
fixes #5021 and probably a bunch of other inventory related glitches

When the server initiates a window close, it does so by sending a ContainerClose to the client, which causes the
client to behave as if it initiated the close itself. It responds by sending a ContainerClose back to the server,
which the server is then expected to respond to.

Sending the client a new window before sending this final response creates buggy behaviour on the client, which
is problematic when switching windows. Therefore, we defer sending any new windows until after the client
responds to our window close instruction, so that we can complete the window handshake correctly.

This is a pile of complicated garbage that only exists because Mojang overengineered the process of opening and
closing inventory windows.
2022-05-20 16:54:15 +01:00
ShockedPlot7560
6482aa7c64 Block: introduce logic for face support types (#4886)
fixes #4856
fixes #458
fixes #4529
fixes #3299

Added API method Block::getSupportType(Facing) : SupportType
Added SupportType enum
fixes torch, lantern, door etc. placement on slabs and upside-down stairs
2022-05-20 15:18:34 +01:00
Dylan K. Taylor
6d941640a9 Merge branch 'stable' into next-minor 2022-05-20 11:14:59 +01:00
Dylan K. Taylor
0ea3861d43 Fixed paintings not working in newly generated worlds
Paintings would not work unless at least one entity was loaded from disk
(or saved).
2022-05-20 11:13:14 +01:00
dependabot[bot]
a323a5e56d Bump docker/login-action from 1 to 2 (#5048)
Bumps [docker/login-action](https://github.com/docker/login-action) from 1 to 2.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](https://github.com/docker/login-action/compare/v1...v2)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-18 13:30:39 +01:00
dependabot[bot]
79caba22a7 Bump docker/build-push-action from 2.10.0 to 3.0.0 (#5046)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 2.10.0 to 3.0.0.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](https://github.com/docker/build-push-action/compare/v2.10.0...v3.0.0)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-18 13:29:44 +01:00
dependabot[bot]
30815bc8a2 Bump actions/upload-artifact from 2 to 3 (#5047)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2 to 3.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-18 13:29:19 +01:00
Dylan K. Taylor
df3a69dcb7 Modernize private property declarations in Threaded classes
I previously avoided this due to being unsure of the effects; however, it's clear that we already use typed properties on Threaded things in other places anyway, and the only known issues are with uninit properties, and arrays.
2022-05-17 22:42:18 +01:00
Dylan K. Taylor
d4b7f66e15 Promote some constructors 2022-05-17 22:34:58 +01:00
Dylan K. Taylor
8e767da29e Modernize some final remaining private property declarations 2022-05-17 21:55:57 +01:00
Dylan K. Taylor
c0b15de504 Modernize private static property declarations 2022-05-17 21:55:16 +01:00
Dylan K. Taylor
1d5430937f Modernize private property declarations in src/timings 2022-05-17 21:54:45 +01:00
Dylan K. Taylor
9de88aa734 Modernize private property declarations in src/scheduler 2022-05-17 21:53:38 +01:00
Dylan K. Taylor
9e59819f06 Modernize private property declarations in src/resourcepacks 2022-05-17 21:52:07 +01:00
Dylan K. Taylor
c60311617d Modernize private property declarations in src/plugin 2022-05-17 21:37:45 +01:00
Dylan K. Taylor
7bc3dcdefd Modernize private property declarations in src/player 2022-05-17 21:36:51 +01:00
Dylan K. Taylor
22edca610c Modernize private property declarations in src/permission 2022-05-17 21:28:42 +01:00
Dylan K. Taylor
6eac2ea7a5 Modernize private property declarations in src/network 2022-05-17 21:22:33 +01:00
Dylan K. Taylor
cd016bedce Network: Improve typeinfo for PHPStan on bannedIps 2022-05-17 21:19:48 +01:00
Dylan K. Taylor
95ad3f16e1 Modernize private property declarations in src/item 2022-05-17 20:59:24 +01:00
Dylan K. Taylor
fb4d332d1a Modernize private property declarations in src/inventory/transaction 2022-05-17 20:51:22 +01:00
Dylan K. Taylor
a06b9294df Modernize private property declarations in src/inventory 2022-05-17 20:49:12 +01:00
Dylan K. Taylor
221c6b8570 Remove useless @var 2022-05-17 20:46:24 +01:00
Dylan K. Taylor
eb95e2a97e Modernize private property declarations in src/event 2022-05-17 20:45:50 +01:00
Dylan K. Taylor
ec6769a6fc Modernize private property declarations in src/entity 2022-05-17 20:42:17 +01:00
Dylan K. Taylor
343a12626e Modernize private property declarations in src/data 2022-05-17 20:35:59 +01:00
Dylan K. Taylor
d11d77d328 Modernize private property declarations in src/crash 2022-05-17 20:35:24 +01:00
Dylan K. Taylor
20eb80fc9a Modernize private property declarations in src/console 2022-05-17 20:34:55 +01:00
Dylan K. Taylor
071067effb Fixed flower pot accepting any block 2022-05-17 20:30:02 +01:00