Package net.minecraft.world.border
Class WorldBorder
java.lang.Object
net.minecraft.world.PersistentState
net.minecraft.world.border.WorldBorder
- Mappings:
Namespace Name named net/minecraft/world/border/WorldBorderintermediary net/minecraft/class_2784official eoc
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static interfaceprivate classstatic final recordprivate class -
Field Summary
FieldsModifier and TypeFieldDescription(package private) WorldBorder.Area(package private) double(package private) doublestatic final com.mojang.serialization.Codec<WorldBorder> (package private) doubleprivate booleanprivate final List<WorldBorderListener> static final double(package private) intprivate final WorldBorder.Properties(package private) doublestatic final doublestatic final PersistentStateType<WorldBorder> (package private) int(package private) int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddListener(WorldBorderListener listener) booleancanCollide(Entity entity, Box box) clamp(double x, double y, double z) clampFloored(double x, double y, double z) clampFloored(BlockPos pos) clampFloored(Vec3d pos) booleancontains(double x, double z) booleancontains(double x, double z, double margin) private booleancontains(double minX, double minZ, double maxX, double maxZ) booleanbooleanbooleanbooleanvoidensureInitialized(long time) doubledoublegetBoundEast(float tickProgress) doubledoublegetBoundNorth(float tickProgress) doubledoublegetBoundSouth(float tickProgress) doubledoublegetBoundWest(float tickProgress) doubledoubledoubleReturns the damage increase per block beyond this border, in hearts.doublegetDistanceInsideBorder(double x, double z) doublegetDistanceInsideBorder(Entity entity) protected List<WorldBorderListener> intReturns the maximum radius of this border, in blocks.doubleReturns the safe zone of this border.doubledoublegetSize()doublelonggetStage()intReturns the warning distance of this border, in blocks.intReturns the warning time of this border, in ticks.voidinterpolateSize(double fromSize, double toSize, long timeDuration, long timeStart) voidremoveListener(WorldBorderListener listener) voidsetCenter(double x, double z) Sets thexandzcoordinates of the center of this border, and notifies its area and all listeners.voidsetDamagePerBlock(double damagePerBlock) Sets the damage per block of this border and notifies all listeners.voidsetMaxRadius(int maxRadius) Sets the maximum radius of this border and notifies its area.voidsetSafeZone(double safeZone) Sets the safe zone of this border and notifies all listeners.voidsetSize(double size) Sets the area of this border to a static area with the givensize, and notifies all listeners.voidsetWarningBlocks(int warningBlocks) Sets the warning blocks of this border and notifies all listeners.voidsetWarningTime(int warningTime) Sets the warning time of this border and notifies all listeners.voidtick()Methods inherited from class net.minecraft.world.PersistentState
isDirty, markDirty, setDirty
-
Field Details
-
STATIC_AREA_SIZE
public static final double STATIC_AREA_SIZE- See Also:
- Mappings:
Namespace Name Mixin selector named STATIC_AREA_SIZELnet/minecraft/world/border/WorldBorder;STATIC_AREA_SIZE:Dintermediary field_33643Lnet/minecraft/class_2784;field_33643:Dofficial aLeoc;a:D
-
MAX_CENTER_COORDINATES
public static final double MAX_CENTER_COORDINATES- See Also:
- Mappings:
Namespace Name Mixin selector named MAX_CENTER_COORDINATESLnet/minecraft/world/border/WorldBorder;MAX_CENTER_COORDINATES:Dintermediary field_36191Lnet/minecraft/class_2784;field_36191:Dofficial bLeoc;b:D
-
CODEC
- Mappings:
Namespace Name Mixin selector named CODECLnet/minecraft/world/border/WorldBorder;CODEC:Lcom/mojang/serialization/Codec;intermediary field_62536Lnet/minecraft/class_2784;field_62536:Lcom/mojang/serialization/Codec;official cLeoc;c:Lcom/mojang/serialization/Codec;
-
TYPE
- Mappings:
Namespace Name Mixin selector named TYPELnet/minecraft/world/border/WorldBorder;TYPE:Lnet/minecraft/world/PersistentStateType;intermediary field_62537Lnet/minecraft/class_2784;field_62537:Lnet/minecraft/class_10741;official dLeoc;d:Lfkj;
-
properties
- Mappings:
Namespace Name Mixin selector named propertiesLnet/minecraft/world/border/WorldBorder;properties:Lnet/minecraft/world/border/WorldBorder$Properties;intermediary field_63953Lnet/minecraft/class_2784;field_63953:Lnet/minecraft/class_2784$class_5200;official eLeoc;e:Leoc$c;
-
initialized
private boolean initialized- Mappings:
Namespace Name Mixin selector named initializedLnet/minecraft/world/border/WorldBorder;initialized:Zintermediary field_63954Lnet/minecraft/class_2784;field_63954:Zofficial fLeoc;f:Z
-
listeners
- Mappings:
Namespace Name Mixin selector named listenersLnet/minecraft/world/border/WorldBorder;listeners:Ljava/util/List;intermediary field_12730Lnet/minecraft/class_2784;field_12730:Ljava/util/List;official gLeoc;g:Ljava/util/List;
-
damagePerBlock
double damagePerBlock- Mappings:
Namespace Name Mixin selector named damagePerBlockLnet/minecraft/world/border/WorldBorder;damagePerBlock:Dintermediary field_12733Lnet/minecraft/class_2784;field_12733:Dofficial hLeoc;h:D
-
safeZone
double safeZone- Mappings:
Namespace Name Mixin selector named safeZoneLnet/minecraft/world/border/WorldBorder;safeZone:Dintermediary field_12731Lnet/minecraft/class_2784;field_12731:Dofficial iLeoc;i:D
-
warningTime
int warningTime- Mappings:
Namespace Name Mixin selector named warningTimeLnet/minecraft/world/border/WorldBorder;warningTime:Iintermediary field_12735Lnet/minecraft/class_2784;field_12735:Iofficial jLeoc;j:I
-
warningBlocks
int warningBlocks- Mappings:
Namespace Name Mixin selector named warningBlocksLnet/minecraft/world/border/WorldBorder;warningBlocks:Iintermediary field_12734Lnet/minecraft/class_2784;field_12734:Iofficial kLeoc;k:I
-
centerX
double centerX- Mappings:
Namespace Name Mixin selector named centerXLnet/minecraft/world/border/WorldBorder;centerX:Dintermediary field_12738Lnet/minecraft/class_2784;field_12738:Dofficial lLeoc;l:D
-
centerZ
double centerZ- Mappings:
Namespace Name Mixin selector named centerZLnet/minecraft/world/border/WorldBorder;centerZ:Dintermediary field_12737Lnet/minecraft/class_2784;field_12737:Dofficial mLeoc;m:D
-
maxRadius
int maxRadius- Mappings:
Namespace Name Mixin selector named maxRadiusLnet/minecraft/world/border/WorldBorder;maxRadius:Iintermediary field_12732Lnet/minecraft/class_2784;field_12732:Iofficial nLeoc;n:I
-
area
WorldBorder.Area area- Mappings:
Namespace Name Mixin selector named areaLnet/minecraft/world/border/WorldBorder;area:Lnet/minecraft/world/border/WorldBorder$Area;intermediary field_12736Lnet/minecraft/class_2784;field_12736:Lnet/minecraft/class_2784$class_2785;official oLeoc;o:Leoc$a;
-
-
Constructor Details
-
WorldBorder
public WorldBorder() -
WorldBorder
- Mappings:
Namespace Name Mixin selector named <init>Lnet/minecraft/world/border/WorldBorder;<init>(Lnet/minecraft/world/border/WorldBorder$Properties;)Vintermediary <init>Lnet/minecraft/class_2784;<init>(Lnet/minecraft/class_2784$class_5200;)Vofficial <init>Leoc;<init>(Leoc$c;)V
-
-
Method Details
-
contains
- Mappings:
Namespace Name Mixin selector named containsLnet/minecraft/world/border/WorldBorder;contains(Lnet/minecraft/util/math/BlockPos;)Zintermediary method_11952Lnet/minecraft/class_2784;method_11952(Lnet/minecraft/class_2338;)Zofficial aLeoc;a(Liz;)Z
-
contains
- Mappings:
Namespace Name Mixin selector named containsLnet/minecraft/world/border/WorldBorder;contains(Lnet/minecraft/util/math/Vec3d;)Zintermediary method_61115Lnet/minecraft/class_2784;method_61115(Lnet/minecraft/class_243;)Zofficial aLeoc;a(Lfrf;)Z
-
contains
- Mappings:
Namespace Name Mixin selector named containsLnet/minecraft/world/border/WorldBorder;contains(Lnet/minecraft/util/math/ChunkPos;)Zintermediary method_11951Lnet/minecraft/class_2784;method_11951(Lnet/minecraft/class_1923;)Zofficial aLeoc;a(Ldtu;)Z
-
contains
- Mappings:
Namespace Name Mixin selector named containsLnet/minecraft/world/border/WorldBorder;contains(Lnet/minecraft/util/math/Box;)Zintermediary method_11966Lnet/minecraft/class_2784;method_11966(Lnet/minecraft/class_238;)Zofficial aLeoc;a(Lfra;)Z
-
contains
private boolean contains(double minX, double minZ, double maxX, double maxZ) - Mappings:
Namespace Name Mixin selector named containsLnet/minecraft/world/border/WorldBorder;contains(DDDD)Zintermediary method_61114Lnet/minecraft/class_2784;method_61114(DDDD)Zofficial aLeoc;a(DDDD)Z
-
contains
public boolean contains(double x, double z) - Mappings:
Namespace Name Mixin selector named containsLnet/minecraft/world/border/WorldBorder;contains(DD)Zintermediary method_35317Lnet/minecraft/class_2784;method_35317(DD)Zofficial aLeoc;a(DD)Z
-
contains
public boolean contains(double x, double z, double margin) - Mappings:
Namespace Name Mixin selector named containsLnet/minecraft/world/border/WorldBorder;contains(DDD)Zintermediary method_39458Lnet/minecraft/class_2784;method_39458(DDD)Zofficial aLeoc;a(DDD)Z
-
clampFloored
- Mappings:
Namespace Name Mixin selector named clampFlooredLnet/minecraft/world/border/WorldBorder;clampFloored(Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/util/math/BlockPos;intermediary method_61117Lnet/minecraft/class_2784;method_61117(Lnet/minecraft/class_2338;)Lnet/minecraft/class_2338;official bLeoc;b(Liz;)Liz;
-
clampFloored
- Mappings:
Namespace Name Mixin selector named clampFlooredLnet/minecraft/world/border/WorldBorder;clampFloored(Lnet/minecraft/util/math/Vec3d;)Lnet/minecraft/util/math/BlockPos;intermediary method_61116Lnet/minecraft/class_2784;method_61116(Lnet/minecraft/class_243;)Lnet/minecraft/class_2338;official bLeoc;b(Lfrf;)Liz;
-
clampFloored
- Mappings:
Namespace Name Mixin selector named clampFlooredLnet/minecraft/world/border/WorldBorder;clampFloored(DDD)Lnet/minecraft/util/math/BlockPos;intermediary method_39538Lnet/minecraft/class_2784;method_39538(DDD)Lnet/minecraft/class_2338;official bLeoc;b(DDD)Liz;
-
clamp
- Mappings:
Namespace Name Mixin selector named clampLnet/minecraft/world/border/WorldBorder;clamp(Lnet/minecraft/util/math/Vec3d;)Lnet/minecraft/util/math/Vec3d;intermediary method_61770Lnet/minecraft/class_2784;method_61770(Lnet/minecraft/class_243;)Lnet/minecraft/class_243;official cLeoc;c(Lfrf;)Lfrf;
-
clamp
- Mappings:
Namespace Name Mixin selector named clampLnet/minecraft/world/border/WorldBorder;clamp(DDD)Lnet/minecraft/util/math/Vec3d;intermediary method_61769Lnet/minecraft/class_2784;method_61769(DDD)Lnet/minecraft/class_243;official cLeoc;c(DDD)Lfrf;
-
getDistanceInsideBorder
- Mappings:
Namespace Name Mixin selector named getDistanceInsideBorderLnet/minecraft/world/border/WorldBorder;getDistanceInsideBorder(Lnet/minecraft/entity/Entity;)Dintermediary method_11979Lnet/minecraft/class_2784;method_11979(Lnet/minecraft/class_1297;)Dofficial aLeoc;a(Lcge;)D
-
asVoxelShape
- Mappings:
Namespace Name Mixin selector named asVoxelShapeLnet/minecraft/world/border/WorldBorder;asVoxelShape()Lnet/minecraft/util/shape/VoxelShape;intermediary method_17903Lnet/minecraft/class_2784;method_17903()Lnet/minecraft/class_265;official bLeoc;b()Lfrz;
-
getDistanceInsideBorder
public double getDistanceInsideBorder(double x, double z) - Mappings:
Namespace Name Mixin selector named getDistanceInsideBorderLnet/minecraft/world/border/WorldBorder;getDistanceInsideBorder(DD)Dintermediary method_11961Lnet/minecraft/class_2784;method_11961(DD)Dofficial bLeoc;b(DD)D
-
canCollide
- Mappings:
Namespace Name Mixin selector named canCollideLnet/minecraft/world/border/WorldBorder;canCollide(Lnet/minecraft/entity/Entity;Lnet/minecraft/util/math/Box;)Zintermediary method_39459Lnet/minecraft/class_2784;method_39459(Lnet/minecraft/class_1297;Lnet/minecraft/class_238;)Zofficial aLeoc;a(Lcge;Lfra;)Z
-
getStage
- Mappings:
Namespace Name Mixin selector named getStageLnet/minecraft/world/border/WorldBorder;getStage()Lnet/minecraft/world/border/WorldBorderStage;intermediary method_11968Lnet/minecraft/class_2784;method_11968()Lnet/minecraft/class_2789;official cLeoc;c()Leob;
-
getBoundWest
public double getBoundWest()- Mappings:
Namespace Name Mixin selector named getBoundWestLnet/minecraft/world/border/WorldBorder;getBoundWest()Dintermediary method_11976Lnet/minecraft/class_2784;method_11976()Dofficial dLeoc;d()D
-
getBoundWest
public double getBoundWest(float tickProgress) - Mappings:
Namespace Name Mixin selector named getBoundWestLnet/minecraft/world/border/WorldBorder;getBoundWest(F)Dintermediary method_75884Lnet/minecraft/class_2784;method_75884(F)Dofficial aLeoc;a(F)D
-
getBoundNorth
public double getBoundNorth()- Mappings:
Namespace Name Mixin selector named getBoundNorthLnet/minecraft/world/border/WorldBorder;getBoundNorth()Dintermediary method_11958Lnet/minecraft/class_2784;method_11958()Dofficial eLeoc;e()D
-
getBoundNorth
public double getBoundNorth(float tickProgress) - Mappings:
Namespace Name Mixin selector named getBoundNorthLnet/minecraft/world/border/WorldBorder;getBoundNorth(F)Dintermediary method_75886Lnet/minecraft/class_2784;method_75886(F)Dofficial bLeoc;b(F)D
-
getBoundEast
public double getBoundEast()- Mappings:
Namespace Name Mixin selector named getBoundEastLnet/minecraft/world/border/WorldBorder;getBoundEast()Dintermediary method_11963Lnet/minecraft/class_2784;method_11963()Dofficial fLeoc;f()D
-
getBoundEast
public double getBoundEast(float tickProgress) - Mappings:
Namespace Name Mixin selector named getBoundEastLnet/minecraft/world/border/WorldBorder;getBoundEast(F)Dintermediary method_75887Lnet/minecraft/class_2784;method_75887(F)Dofficial cLeoc;c(F)D
-
getBoundSouth
public double getBoundSouth()- Mappings:
Namespace Name Mixin selector named getBoundSouthLnet/minecraft/world/border/WorldBorder;getBoundSouth()Dintermediary method_11977Lnet/minecraft/class_2784;method_11977()Dofficial gLeoc;g()D
-
getBoundSouth
public double getBoundSouth(float tickProgress) - Mappings:
Namespace Name Mixin selector named getBoundSouthLnet/minecraft/world/border/WorldBorder;getBoundSouth(F)Dintermediary method_75888Lnet/minecraft/class_2784;method_75888(F)Dofficial dLeoc;d(F)D
-
getCenterX
public double getCenterX()- Mappings:
Namespace Name Mixin selector named getCenterXLnet/minecraft/world/border/WorldBorder;getCenterX()Dintermediary method_11964Lnet/minecraft/class_2784;method_11964()Dofficial hLeoc;h()D
-
getCenterZ
public double getCenterZ()- Mappings:
Namespace Name Mixin selector named getCenterZLnet/minecraft/world/border/WorldBorder;getCenterZ()Dintermediary method_11980Lnet/minecraft/class_2784;method_11980()Dofficial iLeoc;i()D
-
setCenter
public void setCenter(double x, double z) Sets thexandzcoordinates of the center of this border, and notifies its area and all listeners.- Mappings:
Namespace Name Mixin selector named setCenterLnet/minecraft/world/border/WorldBorder;setCenter(DD)Vintermediary method_11978Lnet/minecraft/class_2784;method_11978(DD)Vofficial cLeoc;c(DD)V
-
getSize
public double getSize()- Mappings:
Namespace Name Mixin selector named getSizeLnet/minecraft/world/border/WorldBorder;getSize()Dintermediary method_11965Lnet/minecraft/class_2784;method_11965()Dofficial jLeoc;j()D
-
getSizeLerpTime
public long getSizeLerpTime()- Mappings:
Namespace Name Mixin selector named getSizeLerpTimeLnet/minecraft/world/border/WorldBorder;getSizeLerpTime()Jintermediary method_11962Lnet/minecraft/class_2784;method_11962()Jofficial kLeoc;k()J
-
getSizeLerpTarget
public double getSizeLerpTarget()- Mappings:
Namespace Name Mixin selector named getSizeLerpTargetLnet/minecraft/world/border/WorldBorder;getSizeLerpTarget()Dintermediary method_11954Lnet/minecraft/class_2784;method_11954()Dofficial lLeoc;l()D
-
setSize
public void setSize(double size) Sets the area of this border to a static area with the givensize, and notifies all listeners.- Mappings:
Namespace Name Mixin selector named setSizeLnet/minecraft/world/border/WorldBorder;setSize(D)Vintermediary method_11969Lnet/minecraft/class_2784;method_11969(D)Vofficial aLeoc;a(D)V
-
interpolateSize
public void interpolateSize(double fromSize, double toSize, long timeDuration, long timeStart) - Mappings:
Namespace Name Mixin selector named interpolateSizeLnet/minecraft/world/border/WorldBorder;interpolateSize(DDJJ)Vintermediary method_11957Lnet/minecraft/class_2784;method_11957(DDJJ)Vofficial aLeoc;a(DDJJ)V
-
getListeners
- Mappings:
Namespace Name Mixin selector named getListenersLnet/minecraft/world/border/WorldBorder;getListeners()Ljava/util/List;intermediary method_11970Lnet/minecraft/class_2784;method_11970()Ljava/util/List;official mLeoc;m()Ljava/util/List;
-
addListener
- Mappings:
Namespace Name Mixin selector named addListenerLnet/minecraft/world/border/WorldBorder;addListener(Lnet/minecraft/world/border/WorldBorderListener;)Vintermediary method_11983Lnet/minecraft/class_2784;method_11983(Lnet/minecraft/class_2780;)Vofficial aLeoc;a(Leoa;)V
-
removeListener
- Mappings:
Namespace Name Mixin selector named removeListenerLnet/minecraft/world/border/WorldBorder;removeListener(Lnet/minecraft/world/border/WorldBorderListener;)Vintermediary method_35318Lnet/minecraft/class_2784;method_35318(Lnet/minecraft/class_2780;)Vofficial bLeoc;b(Leoa;)V
-
setMaxRadius
public void setMaxRadius(int maxRadius) Sets the maximum radius of this border and notifies its area.- Mappings:
Namespace Name Mixin selector named setMaxRadiusLnet/minecraft/world/border/WorldBorder;setMaxRadius(I)Vintermediary method_11973Lnet/minecraft/class_2784;method_11973(I)Vofficial aLeoc;a(I)V
-
getMaxRadius
public int getMaxRadius()Returns the maximum radius of this border, in blocks.The default value is 29999984.
- Mappings:
Namespace Name Mixin selector named getMaxRadiusLnet/minecraft/world/border/WorldBorder;getMaxRadius()Iintermediary method_11959Lnet/minecraft/class_2784;method_11959()Iofficial nLeoc;n()I
-
getSafeZone
public double getSafeZone()Returns the safe zone of this border.The default value is 5.0.
- Mappings:
Namespace Name Mixin selector named getSafeZoneLnet/minecraft/world/border/WorldBorder;getSafeZone()Dintermediary method_11971Lnet/minecraft/class_2784;method_11971()Dofficial oLeoc;o()D
-
setSafeZone
public void setSafeZone(double safeZone) Sets the safe zone of this border and notifies all listeners.- Mappings:
Namespace Name Mixin selector named setSafeZoneLnet/minecraft/world/border/WorldBorder;setSafeZone(D)Vintermediary method_11981Lnet/minecraft/class_2784;method_11981(D)Vofficial bLeoc;b(D)V
-
getDamagePerBlock
public double getDamagePerBlock()Returns the damage increase per block beyond this border, in hearts.Once an entity goes beyond the border and the safe zone, damage will be applied depending on the distance traveled multiplied by this damage increase.
The default value is 0.2.
- See Also:
- Mappings:
Namespace Name Mixin selector named getDamagePerBlockLnet/minecraft/world/border/WorldBorder;getDamagePerBlock()Dintermediary method_11953Lnet/minecraft/class_2784;method_11953()Dofficial pLeoc;p()D
-
setDamagePerBlock
public void setDamagePerBlock(double damagePerBlock) Sets the damage per block of this border and notifies all listeners.- Mappings:
Namespace Name Mixin selector named setDamagePerBlockLnet/minecraft/world/border/WorldBorder;setDamagePerBlock(D)Vintermediary method_11955Lnet/minecraft/class_2784;method_11955(D)Vofficial cLeoc;c(D)V
-
getShrinkingSpeed
public double getShrinkingSpeed()- Mappings:
Namespace Name Mixin selector named getShrinkingSpeedLnet/minecraft/world/border/WorldBorder;getShrinkingSpeed()Dintermediary method_11974Lnet/minecraft/class_2784;method_11974()Dofficial qLeoc;q()D
-
getWarningTime
public int getWarningTime()Returns the warning time of this border, in ticks.Once a player goes beyond the border, this is the time before a message is displayed to them.
The default value is 15.
- Mappings:
Namespace Name Mixin selector named getWarningTimeLnet/minecraft/world/border/WorldBorder;getWarningTime()Iintermediary method_11956Lnet/minecraft/class_2784;method_11956()Iofficial rLeoc;r()I
-
setWarningTime
public void setWarningTime(int warningTime) Sets the warning time of this border and notifies all listeners.- Mappings:
Namespace Name Mixin selector named setWarningTimeLnet/minecraft/world/border/WorldBorder;setWarningTime(I)Vintermediary method_11975Lnet/minecraft/class_2784;method_11975(I)Vofficial bLeoc;b(I)V
-
getWarningBlocks
public int getWarningBlocks()Returns the warning distance of this border, in blocks.When an entity approaches the border, this is the distance from which a warning will be displayed.
The default value is 5.
- Mappings:
Namespace Name Mixin selector named getWarningBlocksLnet/minecraft/world/border/WorldBorder;getWarningBlocks()Iintermediary method_11972Lnet/minecraft/class_2784;method_11972()Iofficial sLeoc;s()I
-
setWarningBlocks
public void setWarningBlocks(int warningBlocks) Sets the warning blocks of this border and notifies all listeners.- Mappings:
Namespace Name Mixin selector named setWarningBlocksLnet/minecraft/world/border/WorldBorder;setWarningBlocks(I)Vintermediary method_11967Lnet/minecraft/class_2784;method_11967(I)Vofficial cLeoc;c(I)V
-
tick
public void tick()- Mappings:
Namespace Name Mixin selector named tickLnet/minecraft/world/border/WorldBorder;tick()Vintermediary method_11982Lnet/minecraft/class_2784;method_11982()Vofficial tLeoc;t()V
-
ensureInitialized
public void ensureInitialized(long time) - Mappings:
Namespace Name Mixin selector named ensureInitializedLnet/minecraft/world/border/WorldBorder;ensureInitialized(J)Vintermediary method_75885Lnet/minecraft/class_2784;method_75885(J)Vofficial aLeoc;a(J)V
-