mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-30 15:19:56 +00:00
Merge branch 'release/3.2'
This commit is contained in:
commit
4597899ac3
@ -56,6 +56,7 @@ class Effect{
|
|||||||
public const SATURATION = 23;
|
public const SATURATION = 23;
|
||||||
public const LEVITATION = 24; //TODO
|
public const LEVITATION = 24; //TODO
|
||||||
public const FATAL_POISON = 25;
|
public const FATAL_POISON = 25;
|
||||||
|
public const CONDUIT_POWER = 26;
|
||||||
|
|
||||||
/** @var Effect[] */
|
/** @var Effect[] */
|
||||||
protected static $effects = [];
|
protected static $effects = [];
|
||||||
@ -86,6 +87,7 @@ class Effect{
|
|||||||
self::registerEffect(new Effect(Effect::SATURATION, "%potion.saturation", new Color(0xf8, 0x24, 0x23), false, 1));
|
self::registerEffect(new Effect(Effect::SATURATION, "%potion.saturation", new Color(0xf8, 0x24, 0x23), false, 1));
|
||||||
self::registerEffect(new Effect(Effect::LEVITATION, "%potion.levitation", new Color(0xce, 0xff, 0xff)));
|
self::registerEffect(new Effect(Effect::LEVITATION, "%potion.levitation", new Color(0xce, 0xff, 0xff)));
|
||||||
self::registerEffect(new Effect(Effect::FATAL_POISON, "%potion.poison", new Color(0x4e, 0x93, 0x31), true));
|
self::registerEffect(new Effect(Effect::FATAL_POISON, "%potion.poison", new Color(0x4e, 0x93, 0x31), true));
|
||||||
|
self::registerEffect(new Effect(Effect::CONDUIT_POWER, "%potion.conduitPower", new Color(0x1d, 0xc2, 0xd1)));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -718,7 +718,7 @@ abstract class Living extends Entity implements Damageable{
|
|||||||
* @return bool
|
* @return bool
|
||||||
*/
|
*/
|
||||||
public function canBreathe() : bool{
|
public function canBreathe() : bool{
|
||||||
return $this->hasEffect(Effect::WATER_BREATHING) or !$this->isUnderwater();
|
return $this->hasEffect(Effect::WATER_BREATHING) or $this->hasEffect(Effect::CONDUIT_POWER) or !$this->isUnderwater();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -1 +1 @@
|
|||||||
Subproject commit 66c471358956c4c826837868af04eab08f3cfdbf
|
Subproject commit 0cd3f8ef307a695eb0c4352db79a26bf7a077b8f
|
Loading…
x
Reference in New Issue
Block a user