ShockedPlot7560
aaa37baf2e
handlerListe: reduce code complexity
2023-10-27 22:28:04 +02:00
ShockedPlot7560
243a3035ba
follow up of #6110
2023-10-27 22:14:21 +02:00
ShockedPlot7560
823d4ead6a
inconsistency correction
2023-10-27 22:12:03 +02:00
ShockedPlot7560
ca95b2f28d
fix PHPStan
2023-10-27 22:08:49 +02:00
ShockedPlot7560
cc6e8ef232
move the asynchronous registration of handlers to a dedicated PluginManager function
2023-10-27 21:58:43 +02:00
ShockedPlot7560
5beaa3ce4e
correction of various problems
2023-10-27 21:45:22 +02:00
ShockedPlot7560
7e87fbbb7a
clarifying the exception message
2023-10-27 21:39:18 +02:00
ShockedPlot7560
ed739cff4f
cannot call async event in sync context + remove Event dependency for AsyncEventDelegate
2023-10-27 21:37:56 +02:00
ShockedPlot7560
dc85bba995
merge remote tracking
2023-10-27 21:28:09 +02:00
Dylan K. Taylor
b41960dfec
Merge branch 'stable' into minor-next
2023-10-26 12:55:47 +01:00
Dylan K. Taylor
0b2fc84827
5.7.1 is next
2023-10-26 12:51:45 +01:00
Dylan K. Taylor
22b9e70372
Release 5.7.0
5.7.0
2023-10-26 12:51:45 +01:00
Dylan K. Taylor
a222636476
Merge branch 'legacy/pm4' into stable
2023-10-26 12:47:19 +01:00
Dylan K. Taylor
fb586cc562
4.25.1 is next
2023-10-26 12:43:16 +01:00
Dylan K. Taylor
f3f22ba48b
Release 4.25.0
4.25.0
2023-10-26 12:43:16 +01:00
Dylan K. Taylor
a2e6e2e5b9
Update PHPStan
2023-10-26 12:39:45 +01:00
Dylan K. Taylor
1aaaadb909
1.20.40 changes (PM4)
2023-10-26 12:36:12 +01:00
Dylan K. Taylor
53a740433f
Changes for 1.20.40
2023-10-26 12:32:59 +01:00
Dylan K. Taylor
8491d3c6c0
Merge branch 'stable' into minor-next
2023-10-24 11:56:51 +01:00
Dylan K. Taylor
d637370b83
Wipe internal block AABB cache only for specific blocks that need it
...
the vast majority of blocks don't need this cache erasing, so it's costing performance for no good reason.
2023-10-23 17:38:04 +01:00
Dylan T
1176b7090c
Update src/player/Player.php
...
Co-authored-by: Javier León <58715544+JavierLeon9966@users.noreply.github.com>
2023-10-23 17:31:53 +01:00
Dylan K. Taylor
f655eda3b3
Player: bypass slow function call
...
for some reason the isSpectator() call here can take upwards of 2 microseconds, for no obvious reason. Subsequent calls are much faster, so I think there's some weird cache thing going on here.
2023-10-23 16:05:13 +01:00
Dylan K. Taylor
af432c1a7f
Give neighbour block updates its own timer
...
this way we aren't conflating them with scheduled updates, which are usually caused by e.g. water
2023-10-23 12:33:36 +01:00
Dylan K. Taylor
9fcc9f4338
StringToItemParser: added missing blocks
...
closes #6108
2023-10-23 12:24:02 +01:00
Dylan K. Taylor
41c5f63565
World: remove dead code
2023-10-23 12:17:41 +01:00
Dylan K. Taylor
73b1fba53c
Fixed Promise<null> calling rejection handler given after being successfully resolved
...
closes #6110
this is a weird use case, but it should work nonetheless.
2023-10-23 11:46:08 +01:00
ShockedPlot7560
2b2fa9ddf1
phpstan: populate baseline
2023-10-22 15:45:05 +02:00
ShockedPlot7560
58155a77fb
fix PHPstan
2023-10-22 15:18:39 +02:00
ShockedPlot7560
c250bb0da7
undo Promise covariant + improve array types
2023-10-22 15:08:50 +02:00
ShockedPlot7560
b78ff00418
fix style
2023-10-22 15:06:17 +02:00
ShockedPlot7560
9b2b92ac1f
oops, remove test code
2023-10-22 15:05:06 +02:00
ShockedPlot7560
7a4b9a0367
events: asynchandler is defined by their return type and event type
...
If the event is async and the handler return Promise, it will be handle as an async event.
However, if the event is async and the handler return smth different than Promise, it will be handle synchronously.
An async handler can specify if it wishes to be called with no concurrent handlers with the tag @noConcurrentCall
2023-10-22 15:01:11 +02:00
Dylan K. Taylor
8e17aed4f4
Fix build
2023-10-20 17:43:04 +01:00
Dylan K. Taylor
1f461977d4
Block: Avoid useless Vector3 allocations in getHorizontalSides and getAllSides
2023-10-20 17:28:19 +01:00
Dylan K. Taylor
e4888d7102
ÂCONTRIBUTING.md: restructure, reword and reorganize
...
[ci skip]
2023-10-20 12:12:14 +01:00
Dylan K. Taylor
450ad42202
Added some new recommendations to CONTRIBUTING.md
2023-10-20 11:37:58 +01:00
Dylan K. Taylor
eb935ca80f
ÂLeaves: use a constant for max distance from wood
2023-10-20 11:20:30 +01:00
Dylan K. Taylor
1c5d3b43be
5.6.2 is next
2023-10-20 10:30:50 +01:00
Dylan K. Taylor
decc188302
Release 5.6.1
5.6.1
2023-10-20 10:30:50 +01:00
Dylan K. Taylor
8fa5c7cdab
World: do not apply fake state properties from tile if the block doesn't expect this tile type
...
This was causing a variety of crashes due to incorrect tiles, presumably from PM3 worlds.
2023-10-20 10:28:46 +01:00
Dylan K. Taylor
7dd3a70d2e
Revert "World: discard tiles on load if they aren't the correct type or no tile is expected"
...
This reverts commit 8f804f6f342e650156767372bac2d42b55297361.
This change is too disruptive, since popular plugins like
ExtendedBlocks and ExtendedBlocksConverter relied on custom tiles.
Deleting them at this stage would prevent these plugins from working,
making it impossible to upgrade old data.
An alternative solution to this problem will need to be developed.
2023-10-20 10:16:49 +01:00
Dylan K. Taylor
dbb5a32a96
Liquid: eliminate unnecessary Position allocations and getSide() calls
2023-10-19 17:09:13 +01:00
Dylan K. Taylor
9474324f75
Liquid: simplify code
2023-10-19 17:02:40 +01:00
Dylan K. Taylor
ada37899aa
Liquid: improve code legibility and fix a bunch of PHPStan errors
2023-10-19 17:02:22 +01:00
Dylan K. Taylor
f1440324a7
Update PHPStan baselines
2023-10-19 16:56:15 +01:00
Dylan K. Taylor
73659318f6
World: Avoid unnecessary Vector3 usages in neighbour block update scheduling
...
The old code was allocating 6 Vector3s which were all immediately discarded. In addition, we didn't need to take the performance hit of reading Vector3 properties when we could have just passed integers directly.
The real performance difference of this is likely to be close to zero, but it's still worth doing.
2023-10-19 16:46:52 +01:00
Dylan K. Taylor
f868c1d8c6
Liquid: Update legacy code with Facing::OFFSET
2023-10-19 16:38:34 +01:00
Dylan K. Taylor
114f444ec3
Update PHPStan baseline
2023-10-19 13:28:40 +01:00
Dylan K. Taylor
19a1792184
Fixed behavioural change on invalid Facing introduced by previous commit
...
while this shouldn't be given invalid facings anyway, Vector3::getSide() accepts them and just returns itself.
2023-10-19 13:27:44 +01:00
Dylan K. Taylor
6a3ec70c72
ÂBlock: use Facing::OFFSET in getSide()
...
instead of the comically inefficient getBlock() + throwaway Position->getSide()
This improved the function's performance by 2.3x.
2023-10-19 13:25:32 +01:00