b176f4c12f
Switch to BiomeRegistry
...
I accidentally committed this in c869a7f099
and didn't notice. I intended to use it and never noticed.
2020-11-01 16:47:13 +00:00
d6ed542fcd
Merge remote-tracking branch 'origin/stable' into master
...
# Conflicts:
# composer.json
# composer.lock
# src/CrashDump.php
# src/pocketmine/Server.php
# src/pocketmine/level/format/io/region/McRegion.php
# tests/phpstan/configs/check-explicit-mixed-baseline.neon
# tests/phpstan/configs/l7-baseline.neon
# tests/phpstan/configs/l8-baseline.neon
# tests/travis/setup-php.yml
2020-10-26 16:18:53 +00:00
a01c086481
Introduced VanillaEnchantments registry
2020-10-23 20:48:19 +01:00
44e446b621
Merge remote-tracking branch 'origin/stable' into master
...
# Conflicts:
# build/php
# composer.lock
# phpstan.neon.dist
# resources/vanilla
# src/pocketmine/Server.php
# src/pocketmine/VersionInfo.php
# src/pocketmine/entity/Entity.php
# src/pocketmine/lang/locale
# src/utils/Timezone.php
# tests/phpstan/bootstrap.php
# tests/phpstan/configs/custom-leveldb.neon
2020-10-13 17:51:49 +01:00
40fca0936f
Internet: make getURL() and postURL() return InternetRequestResult objects
...
this reduces the amount of reference parameters, and generally reduces the number of parameters, while guaranteeing consistency of the APIs.
2020-10-09 18:03:20 +01:00
7b02cc3efd
Implemented #3836 : Replace setCancelled() in events with cancel() and uncancel()
...
The motivation for this is to prevent passing a dynamic argument to cancellation, which in almost all cases is a bug in user code. This same mistake also appears in a few places in the PM core (as seen in this commit), but in those cases the mistakes were mostly harmless since they were taking place before the event was actually called.
closes #3836
2020-09-26 14:31:56 +01:00
2c29634d03
Remove VERSION and GIT_COMMIT constants
...
these are now lazily computed in VersionInfo as needed.
2020-07-25 19:17:33 +01:00
2645b19617
Convert VersionInfo into a final class
...
this allows it to be loaded by the autoloader without additional changes.
2020-07-25 19:00:48 +01:00
bc52a38922
Improved network bandwidth data collection
2020-07-21 19:21:27 +01:00
92f6967665
Command: validate permissions, require permission registration in advance of commands using them
...
this fixes #3200 .
This causes permissions to be registered before plugin load, which changes some behaviour, but after discussions on #internals-dev we couldn't see any reason to keep the behaviour the way it was, and several reasons to change it to be something like this.
2020-07-08 13:50:38 +01:00
96541763f1
ConsoleCommandSender: inject Language via constructor
2020-07-01 13:38:05 +01:00
52fd1a8c1d
CommandSender: export getLanguage()
...
this currently serves as a proxy to the server main language, but it can be used by third party implementations to choose a non-Server language.
2020-06-22 20:05:23 +01:00
11eb1f1c5e
imports cleanup
2020-06-18 20:01:19 +01:00
edc3156bea
Rename NetworkCipher -> EncryptionContext
2020-06-18 11:37:53 +01:00
506f98efc4
Eliminate usages of BaseNbtSerializer->readCompressed() and BaseNbtSerializer->writeCompressed()
2020-06-17 14:31:56 +01:00
13031967f4
Merge commit '0029efa37'
...
# Conflicts:
# resources/vanilla
# src/pocketmine/Server.php
2020-06-14 19:36:50 +01:00
c29ed34b54
Merge commit 'f4ee2912db89c6629d4fa191e993f0798035ef20'
...
# Conflicts:
# resources/vanilla
# src/pocketmine/Server.php
2020-06-04 14:13:23 +01:00
c93038f574
Inject WorldProviderManager to WorldManager's constructor, no longer singleton
2020-05-24 19:22:04 +01:00
41566e8077
Server: remove unused BOOTUP_RANDOM constant
...
this used to be used for /dumpmemory filenames, but those were confusing and stupid, and it's not used anymore since March 2018.
2020-05-24 18:33:04 +01:00
fe649d8d70
Extract ServerConfigGroup from Server
...
this API isn't very nice, but it's pretty much the same as the original, and at least this can be _kinda_ unit-tested...
2020-05-24 15:48:03 +01:00
5eadb0ac44
ConsoleCommandSender: be honest about Server dependency
2020-05-23 12:31:22 +01:00
5f2e65d608
QueryHandler: be honest about dependency on Server
2020-05-23 12:28:12 +01:00
23ab6a283b
Separate QueryInfo from QueryRegenerateEvent
...
this removes some useless and confusing APIs from query info.
2020-05-23 11:55:29 +01:00
c9af5ce7a9
Convert GeneratorManager to singleton
2020-05-23 10:13:03 +01:00
640428c415
Convert WorldProviderManager to singleton
2020-05-23 10:02:09 +01:00
8d9759288c
WorldManager: don't hard-depend on server configuration for autosave settings
2020-05-23 09:43:59 +01:00
fcea7da183
WorldManager: allow dataPath to be injected via constructor
2020-05-23 09:37:37 +01:00
3795a13683
Merge commit '2eb62c85f69ebd22b36f29cfb513a579ea570b0c'
...
# Conflicts:
# resources/vanilla
# src/Server.php
2020-05-18 10:29:06 +01:00
3238b4ff33
Remove PluginIdentifiableCommand in favour of a more generic PluginOwned interface
2020-05-11 19:25:52 +01:00
b7cf4f01f9
remove utils\UUID, switch to pocketmine/uuid package
2020-05-11 10:46:48 +01:00
1122f2a29f
phpstorm can't infer these types :(
2020-04-29 13:26:49 +01:00
8093a94e5d
do not hardcode data deserialization into CraftingManager
2020-04-28 18:56:27 +01:00
f9a587d40e
imports cleanup
2020-04-28 17:27:38 +01:00
3be9548b1e
net: compressors are now fully dynamic (or at least the potential to be)
...
the compressor used by RakLibInterface when opening a session is still
hardcoded, but that's because we have no way to select the correct
compressor at that point in the login sequence, since we aren't
propagating the protocol information up from RakLib right now.
2020-04-28 16:21:18 +01:00
d9e4783b24
start making network compressors dynamic
...
this will facilitate future multi version support where compression types are different between versions
2020-04-28 14:47:01 +01:00
a97cafd4f6
moving serializers into protocol namespace
2020-04-27 13:54:39 +01:00
f91e2f41e0
move SendUsageTask to stats namespace
...
maybe separate this out into a library?
2020-04-26 11:42:48 +01:00
7d9df6af6f
Convert EntityFactory to singleton
2020-04-24 22:43:02 +01:00
08ac6a3c43
Convert CreativeInventory to singleton
2020-04-24 00:38:18 +01:00
5a94af40e2
Convert ItemFactory to singleton
2020-04-24 00:18:31 +01:00
13d784cd0c
Convert BlockFactory to singleton
2020-04-23 23:45:13 +01:00
7b3c2a3703
Merge commit '3907a2b6ba58fa49022e3e7c8256731dfa2e0d00'
2020-03-14 13:32:35 +00:00
4c51f1dda3
Scrap TextContainer, make TranslationContainer immutable
...
TextContainer provided zero real value as a base of TranslationContainer, given that it required its own logic to be handled wherever accepted. As such, it's no better than a simple string.
Removing it also allows fixing an ambiguity when embedding translations inside other translations, allowing it to be made immutable.
2020-02-08 13:38:27 +00:00
fb1126797a
Merge branch 'stable'
2020-02-07 18:13:55 +00:00
e3833ba4f0
Merge branch 'stable'
2020-02-01 21:03:21 +00:00
ff63f6d055
fill in more iterable types (master)
2020-02-01 20:19:57 +00:00
cb16f5c142
Merge commit '260ac47588c76a2e6814cfba46773a990fb8c5da'
...
# Conflicts:
# resources/vanilla
# src/Server.php
# src/lang/Language.php
# src/network/mcpe/protocol/AddItemActorPacket.php
# src/network/mcpe/protocol/AddPlayerPacket.php
# src/network/mcpe/protocol/SetActorDataPacket.php
# src/network/mcpe/serializer/NetworkBinaryStream.php
# src/permission/Permission.php
# src/pocketmine/block/Leaves.php
# src/pocketmine/entity/DataPropertyManager.php
# src/pocketmine/entity/Entity.php
# src/pocketmine/item/Banner.php
# src/pocketmine/item/Item.php
# src/pocketmine/level/format/io/LevelProvider.php
# src/pocketmine/level/format/io/LevelProviderManager.php
# src/pocketmine/network/mcpe/protocol/AddActorPacket.php
# src/pocketmine/network/mcpe/protocol/LoginPacket.php
# src/pocketmine/tile/Banner.php
# src/scheduler/BulkCurlTask.php
# src/updater/AutoUpdater.php
# src/utils/Config.php
# src/utils/Utils.php
# src/world/generator/Flat.php
# src/world/generator/Generator.php
2020-01-31 21:07:34 +00:00
ee4757303b
Merge commit '9eebfa7cc30c8a5ac39f192c79023131623ad4b4'
...
# Conflicts:
# resources/vanilla
# src/Server.php
# src/pocketmine/Achievement.php
2020-01-31 20:07:21 +00:00
055b13a6cf
strip extra blank lines (php-cs-fixer)
2020-01-22 15:14:10 +00:00
67bcc1c0fb
phpdoc armageddon for master, pass 1
2020-01-22 11:55:03 +00:00