mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2024-11-21 17:45:20 +00:00
6.3 KiB
6.3 KiB
For Minecraft: Bedrock Edition 1.19.50
This is a minor feature release for PocketMine-MP, introducing some new features and improvements.
Note about API versions
Plugins which don't touch the protocol and compatible with any previous 4.x.y version will also run on these releases and do not need API bumps. Plugin developers should only update their required API to this version if you need the changes in this build.
WARNING: If your plugin uses the protocol, you're not shielded by API change constraints. You should consider using the mcpe-protocol
directive in plugin.yml
as a constraint if you do.
4.13.0-BETA1
Released 18th January 2023.
Gameplay
- Death message is now shown on the death screen when a player dies.
- Armour damage is now only increased if the armour reduced the damage taken.
- Implemented Swift Sneak enchantment.
- Fixed incorrect collision box calculation of walls and glass/bars when connected. Note: Client-side, wall connections are still broken; this only fixes projectile flight server-side.
Performance
- Improved performance of chunk selection for chunk random ticking using a cache. This improves performance of chunk random ticking by 10-20%.
Localization
- Added localized description for the
/dumpmemory
command.
Permissions
- Added the following new core permissions:
pocketmine.command.effect.other
- allows the player to use the/effect
command on other players (default operator only)pocketmine.command.effect.self
- allows the player to use the/effect
command on themselves (default operator only)pocketmine.command.enchant.other
- allows the player to use the/enchant
command on other players (default operator only)pocketmine.command.enchant.self
- allows the player to use the/enchant
command on themselves (default operator only)pocketmine.command.gamemode.other
- allows the player to use the/gamemode
command on other players (default operator only)pocketmine.command.gamemode.self
- allows the player to use the/gamemode
command on themselves (default operator only)pocketmine.command.give.other
- allows the player to use the/give
command on other players (default operator only)pocketmine.command.give.self
- allows the player to use the/give
command on themselves (default operator only)pocketmine.command.spawnpoint.other
- allows the player to use the/spawnpoint
command on other players (default operator only)pocketmine.command.spawnpoint.self
- allows the player to use the/spawnpoint
command on themselves (default operator only)pocketmine.command.teleport.other
- allows the player to use the/teleport
command on other players (default operator only)pocketmine.command.teleport.self
- allows the player to use the/teleport
command on themselves (default operator only)pocketmine.command.title.other
- allows the player to use the/title
command on other players (default operator only)pocketmine.command.title.self
- allows the player to use the/title
command on themselves (default operator only)
Internals
- Decoupled
Player->sendMessage()
andPlayer->sendTranslation()
. - Refactored resource pack loading in
ResourcePackManager
to make it easier to understand. - Client-aware translation processing has been moved to
NetworkSession
due to being client-specific. - Replaced hardcoded strings with constants in various places.
NetworkSession
destructive cleanup is now deferred to the next session tick. This fixes variousInventoryManager
crashes when kicking players during events.- Updated code using
strpos()
to usestr_starts_with()
,str_ends_with()
andstr_contains()
where appropriate. - Added documentation for some internal methods.
API
pocketmine\command
- The following new API methods have been added:
protected VanillaCommand->fetchPermittedPlayerTarget(...) : ?Player
- fetches a player target according to the given sender permissions, or null if not found or not permitted
pocketmine\entity
- The following new API methods have been added:
public Living->getDisplayName() : string
- the name of the entity to be shown in death messages, commands etc.
pocketmine\event\world
- The following new classes have been added:
WorldSoundEvent
- called when a sound is played in a worldWorldParticleEvent
- called when a particle is spawned in a world
pocketmine\item
- The following new API methods have been added:
public Item->onInteractEntity(Player $player, Entity $entity, Vector3 $clickVector) : bool
- called when a player interacts with an entity with this item in hand
pocketmine\lang
Language->translate()
andLanguage->translateString()
no longer parse nested translation in the "base text". This was never intended behaviour, and didn't work beyond the first level anyway.
pocketmine\player
- The following new interfaces have been added:
PlayerDataProvider
- implemented by classes which want to offer storage for player data
- The following new classes have been added:
DatFilePlayerDataProvider
- the default player data provider, which stores.dat
files in theplayers
folderPlayerDataLoadException
- thrown when an error occurs while loading player dataPlayerDataSaveException
- thrown when an error occurs while saving player data
- The following API methods have been deprecated:
Player->sendTranslation()
- usePlayer->sendMessage()
instead with aTranslatable
message
pocketmine\resourcepacks
- The following new API methods have been added:
public ResourcePackManager->setResourceStack(list<ResourcePack> $resourceStack) : void
- sets the list of resource packs to be applied by playerspublic ResourcePackManager->setPackEncryptionKey(string $id, ?string $key) : void
- sets the encryption key to be used for a resource pack
pocketmine\utils
- The following new API methods have been added:
public static Filesystem::fileGetContents(...) : string
- a wrapper aroundfile_get_contents()
which throws an exception on failure
pocketmine\world
- The following new API methods have been added:
public World->requestSafeSpawn(?Vector3 $spawn = null) : Promise<Position>
- an async version ofgetSafeSpawn()
which generates all the needed chunks before returning