public class DamageSourcePredicate
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static DamageSourcePredicate |
ANY |
private java.lang.Boolean |
bypassesArmor |
private java.lang.Boolean |
bypassesInvulnerability |
private java.lang.Boolean |
bypassesMagic |
private EntityPredicate |
directEntity |
private java.lang.Boolean |
isExplosion |
private java.lang.Boolean |
isFire |
private java.lang.Boolean |
isMagic |
private java.lang.Boolean |
isProjectile |
private EntityPredicate |
sourceEntity |
Constructor and Description |
---|
DamageSourcePredicate() |
DamageSourcePredicate(java.lang.Boolean isProjectile,
java.lang.Boolean isExplosion,
java.lang.Boolean bypassesArmor,
java.lang.Boolean bypassesInvulnerability,
java.lang.Boolean bypassesMagic,
java.lang.Boolean isFire,
java.lang.Boolean isMagic,
EntityPredicate directEntity,
EntityPredicate sourceEntity) |
Modifier and Type | Method and Description |
---|---|
static DamageSourcePredicate |
deserialize(com.google.gson.JsonElement element) |
private static java.lang.Boolean |
optionalBoolean(com.google.gson.JsonObject object,
java.lang.String memberName) |
boolean |
test(EntityPlayerMP player,
DamageSource source) |
public static DamageSourcePredicate ANY
private final java.lang.Boolean isProjectile
private final java.lang.Boolean isExplosion
private final java.lang.Boolean bypassesArmor
private final java.lang.Boolean bypassesInvulnerability
private final java.lang.Boolean bypassesMagic
private final java.lang.Boolean isFire
private final java.lang.Boolean isMagic
private final EntityPredicate directEntity
private final EntityPredicate sourceEntity
public DamageSourcePredicate()
public DamageSourcePredicate(@Nullable java.lang.Boolean isProjectile, @Nullable java.lang.Boolean isExplosion, @Nullable java.lang.Boolean bypassesArmor, @Nullable java.lang.Boolean bypassesInvulnerability, @Nullable java.lang.Boolean bypassesMagic, @Nullable java.lang.Boolean isFire, @Nullable java.lang.Boolean isMagic, EntityPredicate directEntity, EntityPredicate sourceEntity)
public boolean test(EntityPlayerMP player, DamageSource source)
public static DamageSourcePredicate deserialize(@Nullable com.google.gson.JsonElement element)
@Nullable private static java.lang.Boolean optionalBoolean(com.google.gson.JsonObject object, java.lang.String memberName)