PocketMine-MP 5.15.1 git-5ef247620a7c6301a849b54e5ef1009217729fc8
SuspiciousStewType.php
1<?php
2
3/*
4 *
5 * ____ _ _ __ __ _ __ __ ____
6 * | _ \ ___ ___| | _____| |_| \/ (_)_ __ ___ | \/ | _ \
7 * | |_) / _ \ / __| |/ / _ \ __| |\/| | | '_ \ / _ \_____| |\/| | |_) |
8 * | __/ (_) | (__| < __/ |_| | | | | | | | __/_____| | | | __/
9 * |_| \___/ \___|_|\_\___|\__|_| |_|_|_| |_|\___| |_| |_|_|
10 *
11 * This program is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License as published by
13 * the Free Software Foundation, either version 3 of the License, or
14 * (at your option) any later version.
15 *
16 * @author PocketMine Team
17 * @link http://www.pocketmine.net/
18 *
19 *
20 */
21
22declare(strict_types=1);
23
24namespace pocketmine\item;
25
28use pocketmine\utils\LegacyEnumShimTrait;
29
46 use LegacyEnumShimTrait;
47
48 case POPPY;
49 case CORNFLOWER;
50 case TULIP;
51 case AZURE_BLUET;
52 case LILY_OF_THE_VALLEY;
53 case DANDELION;
54 case BLUE_ORCHID;
55 case ALLIUM;
56 case OXEYE_DAISY;
57 case WITHER_ROSE;
58
63 public function getEffects() : array{
64 return match($this){
65 self::POPPY => [new EffectInstance(VanillaEffects::NIGHT_VISION(), 80)],
66 self::CORNFLOWER => [new EffectInstance(VanillaEffects::JUMP_BOOST(), 80)],
67 self::TULIP => [new EffectInstance(VanillaEffects::WEAKNESS(), 140)],
68 self::AZURE_BLUET => [new EffectInstance(VanillaEffects::BLINDNESS(), 120)],
69 self::LILY_OF_THE_VALLEY => [new EffectInstance(VanillaEffects::POISON(), 200)],
70 self::DANDELION,
71 self::BLUE_ORCHID => [new EffectInstance(VanillaEffects::SATURATION(), 6)],
72 self::ALLIUM => [new EffectInstance(VanillaEffects::FIRE_RESISTANCE(), 40)],
73 self::OXEYE_DAISY => [new EffectInstance(VanillaEffects::REGENERATION(), 120)],
74 self::WITHER_ROSE => [new EffectInstance(VanillaEffects::WITHER(), 120)]
75 };
76 }