17938 Commits

Author SHA1 Message Date
Dylan K. Taylor
daacc8eddb
Updated setup-php-action to 3.2.0 2024-11-27 17:56:00 +00:00
Akmal Fairuz
269effcecf
Introduce Utils::getRandomFloat() (#6532)
Drop-in replacement for lcg_value() for PHP 8.4
2024-11-26 11:33:29 +00:00
pmmp-restrictedactions-bot[bot]
ae750b60d0 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/12022106146
2024-11-26 01:36:41 +00:00
Dylan K. Taylor
905a10e980
Deprecate InventoryAction->onAddToTransaction()
this never made any sense
2024-11-25 21:39:35 +00:00
Dylan K. Taylor
52fe2cb97f
PermissionManager: deprecate permission subscription system
this is no longer used by the core, and as far as I can tell no plugin uses it either.
it was used in the past for chat broadcast channels, but not anymore.
2024-11-25 21:29:26 +00:00
Dylan T.
8cdc7d7ee1
auto-approve: drop pull_request_review trigger
this doesn't work for PRs from forks, since fork PRs don't have access to repo secrets.

we'll need some more advanced mechanism to avoid redundant reviews, but that's a job for another time.
2024-11-25 20:43:59 +00:00
Dylan K. Taylor
12ae8dc03b
Merge branch 'stable' into minor-next 2024-11-25 14:32:30 +00:00
Dylan K. Taylor
a9787f0d99
Fix PHPStan error 2024-11-25 14:32:17 +00:00
Dylan K. Taylor
5325ecee37
Deal with a whole lot of PHPStan suppressed key casting errors
closes #6534
2024-11-25 14:30:58 +00:00
Dylan K. Taylor
30ee0aa63d
Merge branch 'stable' into minor-next 2024-11-24 23:50:56 +00:00
Dylan K. Taylor
aef4fa7174
Remove unused variable 2024-11-24 23:50:30 +00:00
Dylan K. Taylor
53aa380ca3
Candle: fix extinguish logic
closes #5983
2024-11-24 23:49:32 +00:00
zSALLAZAR
a5f607138c
Implement Ice Bomb (#5452)
Co-authored-by: Dylan K. Taylor <dktapps@pmmp.io>
2024-11-24 15:01:26 +00:00
ShockedPlot7560
8338ebaffd
Add generic types for TaskHandler (#6030) 2024-11-24 14:14:34 +00:00
pmmp-restrictedactions-bot[bot]
082119cfd2 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11990667732
2024-11-23 21:49:01 +00:00
Dylan T.
7460e12b6a
pr-remove-waiting-label: suppress failure on 404 errors
this usually means the label wasn't on the PR in the first place
2024-11-23 21:48:30 +00:00
pmmp-restrictedactions-bot[bot]
a53b0116a0 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11990103798
2024-11-23 20:14:23 +00:00
Dylan T.
5b72f202bf
actions: automatically remove waiting label from PRs on synchronize
there are probably other conditions where we'd want to remove this, but this will do for now.
2024-11-23 20:13:46 +00:00
pmmp-restrictedactions-bot[bot]
8b6adf86d6 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11989715327
2024-11-23 19:10:12 +00:00
Dylan T.
0070426e97
auto-approve: only re-review if previous review was dismissed
this avoids unnecessary spam when someone clicks "Update branch" on the PR.
2024-11-23 19:07:24 +00:00
pmmp-restrictedactions-bot[bot]
a523ed6e40 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11964819241
2024-11-22 01:36:16 +00:00
GameParrot
7c2ed7d884
Fix insta break check (#6528) 2024-11-21 02:22:10 +00:00
Dylan K. Taylor
1e3a858de6
Add setUp and tearDown for event unit tests 2024-11-20 16:42:50 +00:00
Dylan K. Taylor
844ba0ff9f
Move event test fixtures to a subdirectory 2024-11-20 15:40:34 +00:00
Dylan K. Taylor
49bdaee930
Move event handler inheritance test to PHPUnit using mock objects
this is dodgy and we shouldn't rely on it long term.

relates to #6524
2024-11-20 15:38:51 +00:00
Dylan T.
9195c88670
ConsoleReader: Use proc_open()'s socket support to send commands back to the main server process (#5273)
Support for this was introduced in PHP 8.0, though not mentioned in any changelog: php/php-src#5777

This simplifies the subprocess handling considerably. However, there is a potential for problems if PHP generates any E_* errors, since these get written to STDOUT as well.
To avoid error messages being treated as a command, a hash is attached to each IPC message, seeded with an incrementing counter. This prevents error messages causing command replays or unintended commands.

Unfortunately, PHP doesn't support binding pipes other than stdin/stdout/stderr on Windows for the child process, so we have to use stdout for this. In the future, if it becomes possible, a dedicated pipe for the purpose should be introduced. We'd need something like php://fd/<number> to work on Windows.
2024-11-20 14:56:52 +00:00
pmmp-restrictedactions-bot[bot]
ae19d05fd5 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11924942897
2024-11-20 01:27:30 +00:00
Dylan T.
bf7a53b00f
Update api-change-request.md
[ci skip]
2024-11-19 17:47:46 +00:00
Markus Staab
e710b3750f
Adjust pretty name of closures on PHP 8.4 (#6351)
related to https://github.com/php/php-src/pull/13550

see analog symfony change: https://github.com/symfony/symfony/pull/54614
2024-11-19 17:05:21 +00:00
pmmp-restrictedactions-bot[bot]
8ccd1edb17 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11904511045
2024-11-19 01:36:11 +00:00
Akmal Fairuz
faf1e26bac
Fix: implicitly nullable parameter declarations deprecated (#6522) 2024-11-18 23:54:22 +00:00
pmmp-restrictedactions-bot[bot]
b4259ef988 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11874902000
2024-11-17 01:39:52 +00:00
Dylan T.
b2aa6396c3
auto-approve: don't request approvals for draft PRs 2024-11-16 23:15:07 +00:00
ipad54
1555fa17e7
Added ability to pick end crystal item (#6509) 2024-11-16 19:06:03 +00:00
ipad54
e77f2c5198
Implemented End Crystal (#4715)
Co-authored-by: Dylan T. <dktapps@pmmp.io>
2024-11-16 17:57:57 +00:00
pmmp-restrictedactions-bot[bot]
e8e441f739 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11866065217
2024-11-16 01:37:27 +00:00
Dylan T.
48a908ee8c
maybe making this specific to gameplay wasn't a good idea 2024-11-16 01:36:51 +00:00
pmmp-restrictedactions-bot[bot]
dc87a2b10e Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11865975725
2024-11-16 01:26:31 +00:00
Javier León
d3add78d3e
Add support for basic entity picking via middle-click (#5397)
Support for more advanced stuff like NBT copying wasn't added in this PR, as the NBT used by PM is currently an inconsistent mess and doesn't play nice with vanilla. In the interests of avoiding this mess propagating, it's been left for another time.

Adds PlayerEntityPickEvent a la PlayerBlockPickEvent
and Entity->getPickedItem().
2024-11-15 21:27:10 +00:00
Dylan T.
ff695a5f97
PlayerInteractEvent: added APIs to independently control reaction of item and block (#4683)
This allows, for example, banning the usage of spawn eggs, without preventing opening of doors, without the need for item ID whitelists.

It also allows customizing the behaviour of item and block interactions when sneaking - it's now possible to force spawn eggs to work when sneaking, or force containers to open.

Finally, this also allows preventing any interaction at all without preventing block placement (by setting both to false). Since cancelling the event will typically prevent placement too (which might not be desired).

Side note: Blocks are now always synced when right-clicking on a block.
This differs from the previous behaviour, where the blocks were only synced when the action "failed".
However, since this change introduces a situation where the action may succeed but have different results than the client expects, it's best to just always sync blocks in this situation.

Fixes #3267
2024-11-15 21:19:54 +00:00
Dylan T.
4b630cb726
start.sh: print warnings on unusual exit codes from the server process (#6497) 2024-11-15 21:14:21 +00:00
Dylan T.
4331f69b9c
Update team-pr-auto-approve.yml 2024-11-15 20:44:51 +00:00
github-actions
fb1213e964 Merge 'stable' into 'minor-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/11862895039
2024-11-15 20:21:32 +00:00
Dylan T.
8a693f2a4c
team-pr-auto-approve: Use RestrictedActions auto approver 2024-11-15 20:08:54 +00:00
bonbionseker
8474eaf5f1
Adjust Sugar Cane to break when there is no water (#6486) 2024-11-15 16:27:27 +00:00
ipad54
a75d4687ce
Implemented vanilla /xp command (#6429) 2024-11-15 16:09:55 +00:00
ipad54
0b0c425805
Extract glow lichen multi face logic into traits (#6396)
This will be useful for future block additions
2024-11-15 15:47:26 +00:00
ipad54
b5469dede2
Flowable blocks now can't be placed inside liquid (#5392) 2024-11-15 00:10:43 +00:00
Dylan K. Taylor
e0d270a870
Merge branch 'minor-next' of github.com:pmmp/PocketMine-MP into minor-next 2024-11-14 23:14:33 +00:00
Dylan K. Taylor
2d9cee3d62
Update Language dependency 2024-11-14 23:14:23 +00:00