PHP Class pocketmine\event\entity\EntityDamageEvent

Inheritance: extends EntityEvent, implements pocketmine\event\Cancellable
Afficher le fichier Open project: iTXTech/Genisys Class Usage Examples

Méthodes publiques

Свойство Type Description
$handlerList

Méthodes publiques

Méthode Description
__construct ( Entity $entity, integer $cause, integer | int[] $damage )
createThornsDamage ( )
getCause ( ) : integer
getDamage ( integer $type = self::MODIFIER_BASE ) : integer
getFinalDamage ( ) : integer
getFireProtectL ( ) : Int
getOriginalDamage ( integer $type = self::MODIFIER_BASE ) : integer
getRateDamage ( integer $type = self::MODIFIER_BASE ) : float
getThornsDamage ( )
getUsedArmors ( ) : Item
isApplicable ( integer $type ) : boolean
setDamage ( float $damage, integer $type = self::MODIFIER_BASE )
setRateDamage ( float $damage, integer $type = self::MODIFIER_BASE )
setThornsArmorUse ( ) : boolean
useArmors ( ) : boolean

Method Details

__construct() public méthode

public __construct ( Entity $entity, integer $cause, integer | int[] $damage )
$entity pocketmine\entity\Entity
$cause integer
$damage integer | int[]

createThornsDamage() public méthode

public createThornsDamage ( )

getCause() public méthode

public getCause ( ) : integer
Résultat integer

getDamage() public méthode

public getDamage ( integer $type = self::MODIFIER_BASE ) : integer
$type integer
Résultat integer

getFinalDamage() public méthode

public getFinalDamage ( ) : integer
Résultat integer

getFireProtectL() public méthode

public getFireProtectL ( ) : Int
Résultat Int $fireProtectL

getOriginalDamage() public méthode

public getOriginalDamage ( integer $type = self::MODIFIER_BASE ) : integer
$type integer
Résultat integer

getRateDamage() public méthode

public getRateDamage ( integer $type = self::MODIFIER_BASE ) : float
$type integer
Résultat float 1 - the percentage

getThornsDamage() public méthode

public getThornsDamage ( )

getUsedArmors() public méthode

public getUsedArmors ( ) : Item
Résultat pocketmine\item\Item $usedArmors notice: $usedArmors $index->$cost $index: the $index of ArmorInventory $cost: the num of durability cost

isApplicable() public méthode

public isApplicable ( integer $type ) : boolean
$type integer
Résultat boolean

setDamage() public méthode

public setDamage ( float $damage, integer $type = self::MODIFIER_BASE )
$damage float
$type integer

setRateDamage() public méthode

public setRateDamage ( float $damage, integer $type = self::MODIFIER_BASE )
$damage float
$type integer Notice:If you want to add/reduce the damage without reducing by Armor or effect. set a new Damage using setDamage Notice:If you want to add/reduce the damage within reducing by Armor of effect. Plz change the MODIFIER_BASE Notice:If you want to add/reduce the damage by multiplying. Plz use this function.

setThornsArmorUse() public méthode

public setThornsArmorUse ( ) : boolean
Résultat boolean should be used after getThornsDamage()

useArmors() public méthode

public useArmors ( ) : boolean
Résultat boolean

Property Details

$handlerList public_oe static_oe property

public static $handlerList