Commit Graph

13358 Commits

Author SHA1 Message Date
1533789f35 Player: fixed not subscribing to own inventory updates
fixes #4211
2021-05-09 19:36:36 +01:00
922164ff2c Updated composer dependencies 2021-05-08 21:15:13 +01:00
20197e6813 RakLibServer: clean up constructor parameters 2021-05-08 20:13:29 +01:00
1003fde2fc RakLibServer: make all parameters mandatory 2021-05-08 20:11:16 +01:00
2ce6a87d05 getSafeSpawn() may throw if the target terrain is not generated 2021-05-08 16:22:13 +01:00
e9f3cefe94 Default world might be null 2021-05-08 16:21:34 +01:00
027109075c WorldManager: don't recalculate the spawn point for every player teleported during world unload 2021-05-08 16:19:22 +01:00
624495f4d3 Added a generic Promise type
I anticipate increasing demand for promises, and since all the libraries I could find suck, we'll stick to our own impl for now.
2021-05-08 15:57:30 +01:00
33eb97da97 Remove dead PHPStan pattern 2021-05-08 15:53:55 +01:00
6384b6602c phpstorm you piece of shit 2021-05-07 23:55:49 +01:00
998a583815 World: Fixed inverted completion callbacks for chunk population
this would have caused any chunk populated by a plugin to remain loaded forever.
2021-05-07 23:39:44 +01:00
f9bfc0df73 NetworkSession: don't crash on teleporting to other world during PlayerLoginEvent 2021-05-07 22:47:06 +01:00
5324474194 Merge remote-tracking branch 'origin/stable' 2021-05-07 20:47:35 +01:00
fb4796f35e Added PhpStorm code style and file templates 2021-05-07 20:44:46 +01:00
6cb285d4a9 Added constants for the handler tag types 2021-05-06 18:40:14 +01:00
742f86e022 Rename DestroyBlockParticle -> BlockBreakParticle
closes #3461

literally every other particle/sound has the subject first, followed by the (optional) verb, and finally Particle (or Sound).
In addition, we refer to breaking blocks as 'break' everywhere except here, where we refer to it as 'destroy'.
2021-05-06 18:33:18 +01:00
7d1c4efdfb Updated composer dependencies 2021-05-06 18:17:05 +01:00
7b2c6c5ceb Avoid more $this refs on long-life closures 2021-05-06 14:27:56 +01:00
c356abb917 BlockTransaction: remove cyclic reference to self in callbacks 2021-05-06 14:27:08 +01:00
01794adef1 ... 2021-05-05 22:24:23 +01:00
5e5277acb5 Merge branch 'stable' 2021-05-05 22:22:32 +01:00
0c2ba66078 Updated build/php submodule to pmmp/php-build-scripts@07129c61d6 2021-05-05 22:15:48 +01:00
17bbb9330f Updated RakLib, require pocketmine/raklib-ipc 2021-05-05 21:31:48 +01:00
cc73571307 Updated composer dependencies 2021-05-05 19:43:39 +01:00
73420819f6 Clean PHPStan baselines 2021-05-05 14:51:39 +01:00
652de2632a Rough OffHand implementation
this doesn't do stuff like taking arrows from offhand yet.
2021-05-05 14:46:51 +01:00
e8cb49f7ae php-cs-fixer fixing php-cs-fixer's own mess 2021-05-05 11:25:11 +01:00
4ca5558ec1 Merge remote-tracking branch 'origin/stable' 2021-05-05 11:14:01 +01:00
267b49247e Updated composer deps (except pocketmine/nbt) 2021-05-04 22:27:34 +01:00
c29cd8e2eb actions: added PHP script to update versions 2021-05-04 22:21:45 +01:00
a13b0c98a1 Updated to PHP-CS-Fixer 3.0.0 2021-05-04 22:18:18 +01:00
e6ff908e18 actions: update PHP versions 2021-05-04 21:52:17 +01:00
176ca3fd2f shut 2021-05-02 14:56:56 +01:00
b8645f5c15 Clean up EnderChestInventory implementation
now, EnderChestInventory is just a temporary window, much like anvil/enchanting windows. It provides a gateway to the player's PlayerEnderInventory.

This removes one of the remaining obstacles to disallowing null World in Position constructor.
2021-05-02 14:26:27 +01:00
129ca7fee0 Silence a PHPStan bug
I'm not able to reproduce this one on the playground, but it still shows up even when disabling certain phpdocs...
2021-05-02 13:55:32 +01:00
4c783f1037 shut 2021-05-02 13:43:37 +01:00
988c976459 Remove unused import 2021-05-02 13:40:18 +01:00
9b8f32c584 Extract inventory helper methods from BaseInventory to a trait
this allows easier alternate implementations of Inventory that don't extend BaseInventory (e.g. double chest, or delegate inventory).
2021-05-02 13:38:49 +01:00
c47ecb55c0 Sign: Do not allow edits by any player except the one who placed it, and only while that player is online
signs now become finalized if:
- the player quits and rejoins (because the entity runtime ID of the player will not be the same)
- the chunk is unloaded and reloaded (because the tagged entity runtime ID is not saved).

closes #4198
2021-05-02 13:22:31 +01:00
c19d2fe891 Bump phpstan/phpstan from 0.12.84 to 0.12.85 (#4199)
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 0.12.84 to 0.12.85.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Commits](https://github.com/phpstan/phpstan/compare/0.12.84...0.12.85)

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

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2021-05-01 23:24:49 +01:00
f195f24f4f Upgrade to GitHub-native Dependabot (#4201) 2021-05-01 23:24:35 +01:00
f538440bce De-spaghettify the hierarchy for chest inventories 2021-04-30 13:44:39 +01:00
d37016f43b Vine: added API to get/set faces 2021-04-30 13:35:38 +01:00
726978b8f1 Migrate all coloured blocks (except glazed terracotta) to dynamic colours 2021-04-29 20:11:03 +01:00
593a8ac529 Added Loom blocks
these don't support doing patterns yet, but their inventories work.
2021-04-29 19:51:09 +01:00
4b5f279a3e UseItemOnEntityTransactionData: added missing type 2021-04-29 19:13:52 +01:00
b33bf1f433 Unfuck banners ... 2021-04-28 18:44:21 +01:00
d5e5a81cff Don't explode when data contains invalid dye colour IDs 2021-04-28 13:39:03 +01:00
a44203a3d4 Separate BannerPatternLayer from BannerPatternType 2021-04-28 12:47:42 +01:00
2bc0f9f7a2 TimingsCommand: do not enable timings if they are already enabled
this causes timings to be reset, which is potentially undesirable (loss of already-collected timing data).
closes #4194
2021-04-27 22:39:13 +01:00