Package api.block.beacon
Class AmbientBeaconEffect
java.lang.Object
api.block.beacon.BeaconEffect
api.block.beacon.AmbientBeaconEffect
- Direct Known Subclasses:
CompanionBeaconEffect,EnderAntennaBeaconEffect,NauseaBeaconEffect,PotionBeaconEffect,SpawnAnchorBeaconEffect
-
Field Summary
FieldsFields inherited from class api.block.beacon.BeaconEffect
rangePerLevel -
Constructor Summary
ConstructorsConstructorDescriptionAmbientBeaconEffect(String effectName) AmbientBeaconEffect(String effectName, boolean isGlobal) AmbientBeaconEffect(String effectName, boolean isGlobal, boolean hasCooldown) AmbientBeaconEffect(String effectName, boolean isGlobal, boolean hasCooldown, long cooldownTime) AmbientBeaconEffect(String effectName, boolean isGlobal, boolean hasCooldown, long cooldownTime, int effectDuration) -
Method Summary
Modifier and TypeMethodDescriptionvoidonAmbientUpdate(BeaconEffectLocation effectLocation, World world) voidonPlayerEffectUpdate(EntityPlayer player, int level) voidonPowerChange(int newPowerLevel, int oldPowerLevel, TileEntityBeacon beacon) voidonUpdate(TileEntityBeacon beacon) Only gets called when beaconEffectClass !protected voidupdateAmbientBeaconListForStateChange(int newPowerLevel, int oldPowerLevel, TileEntityBeacon beacon) Methods inherited from class api.block.beacon.BeaconEffect
getMagneticFieldLevel, onPowerOff, onPowerOn, updateGlobalMagneticFieldListForStateChange
-
Field Details
-
effectName
-
isGlobal
public final boolean isGlobal -
hasCooldown
public final boolean hasCooldown -
cooldownTime
public final long cooldownTime -
effectDuration
public final int effectDuration
-
-
Constructor Details
-
AmbientBeaconEffect
-
AmbientBeaconEffect
-
AmbientBeaconEffect
-
AmbientBeaconEffect
public AmbientBeaconEffect(String effectName, boolean isGlobal, boolean hasCooldown, long cooldownTime) -
AmbientBeaconEffect
public AmbientBeaconEffect(String effectName, boolean isGlobal, boolean hasCooldown, long cooldownTime, int effectDuration)
-
-
Method Details
-
onPlayerEffectUpdate
-
onAmbientUpdate
-
onUpdate
Description copied from class:BeaconEffectOnly gets called when beaconEffectClass != null, isOn() and getLevels() > 0- Specified by:
onUpdatein classBeaconEffect
-
onPowerChange
- Overrides:
onPowerChangein classBeaconEffect
-
updateAmbientBeaconListForStateChange
protected void updateAmbientBeaconListForStateChange(int newPowerLevel, int oldPowerLevel, TileEntityBeacon beacon)
-