github pmmp/PocketMine-MP 3.2.0
PocketMine-MP 3.2.0

latest releases: 5.20.1, 5.20.0, 5.19.0...
6 years ago

For Minecraft: Bedrock Edition 1.6.0

This is a new minor feature release, including support for Minecraft Bedrock 1.6.0, some new minor gameplay features and some API deprecations and additions.

Note

Plugins compatible with any previous 3.x.y version will also run on this build and do not need API bumps.

However, some API features have been deprecated in this version. Plugin developers do not need to do anything about these deprecations immediately, however they may raise harmless warnings if used.

Features marked @deprecated are recommended not to be used, but will continue to work for any future 3.x.y versions. They will be removed in the next major release (4.0).

Changes

Core

  • Level generators are now registered only when needed instead of as soon as a worker starts. This drastically reduces memory consumption on servers with lots of workers.
  • Async workers are now garbage-collected along with everything else on the default schedule. Idle workers with 0 queued tasks will be shutdown and removed from the pool to reduce memory usage.
  • UPnP error messages are now more informative of troubleshooting steps.
  • Errors are no longer caught in cases where they are unrecoverable.

API

Entity

  • Arrow pickup mode can now be controlled via Arrow->setPickupMode(). This accepts one of three Arrow constants: PICKUP_NONE, PICKUP_ANY, PICKUP_CREATIVE.
  • Added new API methods Projectile->getBaseDamage() and Projectile->setBaseDamage().
  • Added new API methods Entity->getScoreTag() and Entity->setScoreTag().

Events

  • The Listener interface has now received in-depth documentation about its behaviour and uses. See the top of the Listener class to read it.
  • It is now possible to declare @ignoreCancelled on an event handler without specifying true or false. If no value is found, true will be assumed.
  • ServerCommandEvent and RemoteServerCommandEvent are now @deprecated and their usage discouraged. A new generic CommandEvent has been introduced in its place, which allows capturing commands from any type of command sender. This was done in response to difficulties of code duplication when wanting to intercept commands from both console and players.
  • EntityDamageEvent
    • Added MODIFIER_WEAPON_ENCHANTMENTS constant for attack damage bonuses due to enchantments like Sharpness.
    • Added new API methods getAttackCooldown() and setAttackCooldown() to allow controlling Living entities attack cooldown times (default 10 ticks).
  • PlayerDeathEvent: Added new static method deriveMessage().
  • PlayerKickEvent: Added new method setReason().

Forms

  • Added a new pocketmine\form\Form interface. Implementing this interface permits custom form implementations to make use of Player->sendForm(), eliminating the need to handle packets directly and also solving the form ID collision problem.

Items

  • Item and ItemFactory now support negative item IDs (needed for future extended blocks support).
  • Updated ItemIds interface with new constants.

Permission

  • Added a new PermissionManager class which encapsulates all of the permission-management functionality originally bloating PluginManager. The API is identical to that of PluginManager's permission API. All methods moved to PermissionManager have @deprecated redirects remaining behind in PluginManager, which will be removed in the next major release (4.0).

Plugin

  • PluginBase->getConfig() will now automatically save the default config if it does not already exist.
  • Plugin data directories will now be automatically created on plugin load, eliminating the need for boilerplate @mkdir($this->getDataFolder()) calls at the top of every plugin.

Tile

  • Tile::createNBT() will now throw a BadMethodCallException when called directly.

Utils

  • Utils::getURL(), Utils::postURL(), Utils::simpleCurl() and Utils::getIP() have been moved to a new pocketmine\utils\Internet class. The original methods are @deprecated and will be removed for the next major version (4.0).
  • Removed the ability for Config to be asynchronously saved. This was discussed for removal because of various problems that it causes. It was deemed not worth fixing since Config saving should not be significant enough to cause problems anyway. See #2298 for details.

Server

  • Deprecated level parameter of findEntity(). This parameter was premature optimization. Code using it will continue to work as before.

Gameplay

General

  • Air bubbles are now regenerated at the same speed as vanilla UpdateAquatic, instead of instantly when leaving water.
  • Implemented Conduit Power effect.

Enchantments

  • Implemented the following enchantments: Thorns, Sharpness, Knockback, Fire Aspect, Power, Punch, Flame, Infinity, Mending.

Items

  • Added the following new items: Scute

Don't miss a new PocketMine-MP release

NewReleases is sending notifications on new releases.