类 StructureWeightSampler
- java.lang.Object
-
- net.minecraft.world.gen.StructureWeightSampler
-
public class StructureWeightSampler extends Object
Applies weights to noise values if they are near structures, placing terrain under them and hollowing out the space above them.- Mappings:
Namespace Name official cofintermediary net/minecraft/class_5817named net/minecraft/world/gen/StructureWeightSampler
-
-
字段概要
字段 修饰符和类型 字段 说明 static intfield_31461private static intfield_31462static StructureWeightSamplerINSTANCEprivate ObjectListIterator<JigsawJunction>junctionIteratorprivate ObjectList<JigsawJunction>junctionsprivate ObjectListIterator<StructurePiece>pieceIteratorprivate ObjectList<StructurePiece>piecesprivate static float[]STRUCTURE_WEIGHT_TABLE
-
构造器概要
构造器 限定符 构造器 说明 privateStructureWeightSampler()protectedStructureWeightSampler(StructureAccessor accessor, Chunk chunk)
-
方法概要
所有方法 静态方法 实例方法 具体方法 修饰符和类型 方法 说明 private static doublecalculateStructureWeight(int x, int y, int z)Calculates the structure weight for the given position.private static doublegetMagnitudeWeight(int x, int y, int z)private static doublegetStructureWeight(int x, int y, int z)Gets the structure weight from the array from the given position, or 0 if the position is out of bounds.protected doublegetWeight(int x, int y, int z)Gets the weight of the structures near the given position.
-
-
-
字段详细资料
-
INSTANCE
public static final StructureWeightSampler INSTANCE
- Mappings:
Namespace Name Mixin selector official aLcof;a:Lcof;intermediary field_28740Lnet/minecraft/class_5817;field_28740:Lnet/minecraft/class_5817;named INSTANCELnet/minecraft/world/gen/StructureWeightSampler;INSTANCE:Lnet/minecraft/world/gen/StructureWeightSampler;
-
field_31461
public static final int field_31461
- 另请参阅:
- 常量字段值
- Mappings:
Namespace Name Mixin selector official bLcof;b:Iintermediary field_31461Lnet/minecraft/class_5817;field_31461:Inamed field_31461Lnet/minecraft/world/gen/StructureWeightSampler;field_31461:I
-
field_31462
private static final int field_31462
- 另请参阅:
- 常量字段值
- Mappings:
Namespace Name Mixin selector official cLcof;c:Iintermediary field_31462Lnet/minecraft/class_5817;field_31462:Inamed field_31462Lnet/minecraft/world/gen/StructureWeightSampler;field_31462:I
-
STRUCTURE_WEIGHT_TABLE
private static final float[] STRUCTURE_WEIGHT_TABLE
- Mappings:
Namespace Name Mixin selector official dLcof;d:[Fintermediary field_28741Lnet/minecraft/class_5817;field_28741:[Fnamed STRUCTURE_WEIGHT_TABLELnet/minecraft/world/gen/StructureWeightSampler;STRUCTURE_WEIGHT_TABLE:[F
-
pieces
private final ObjectList<StructurePiece> pieces
- Mappings:
Namespace Name Mixin selector official eLcof;e:Lit/unimi/dsi/fastutil/objects/ObjectList;intermediary field_28742Lnet/minecraft/class_5817;field_28742:Lit/unimi/dsi/fastutil/objects/ObjectList;named piecesLnet/minecraft/world/gen/StructureWeightSampler;pieces:Lit/unimi/dsi/fastutil/objects/ObjectList;
-
junctions
private final ObjectList<JigsawJunction> junctions
- Mappings:
Namespace Name Mixin selector official fLcof;f:Lit/unimi/dsi/fastutil/objects/ObjectList;intermediary field_28743Lnet/minecraft/class_5817;field_28743:Lit/unimi/dsi/fastutil/objects/ObjectList;named junctionsLnet/minecraft/world/gen/StructureWeightSampler;junctions:Lit/unimi/dsi/fastutil/objects/ObjectList;
-
pieceIterator
private final ObjectListIterator<StructurePiece> pieceIterator
- Mappings:
Namespace Name Mixin selector official gLcof;g:Lit/unimi/dsi/fastutil/objects/ObjectListIterator;intermediary field_28744Lnet/minecraft/class_5817;field_28744:Lit/unimi/dsi/fastutil/objects/ObjectListIterator;named pieceIteratorLnet/minecraft/world/gen/StructureWeightSampler;pieceIterator:Lit/unimi/dsi/fastutil/objects/ObjectListIterator;
-
junctionIterator
private final ObjectListIterator<JigsawJunction> junctionIterator
- Mappings:
Namespace Name Mixin selector official hLcof;h:Lit/unimi/dsi/fastutil/objects/ObjectListIterator;intermediary field_28745Lnet/minecraft/class_5817;field_28745:Lit/unimi/dsi/fastutil/objects/ObjectListIterator;named junctionIteratorLnet/minecraft/world/gen/StructureWeightSampler;junctionIterator:Lit/unimi/dsi/fastutil/objects/ObjectListIterator;
-
-
构造器详细资料
-
StructureWeightSampler
protected StructureWeightSampler(StructureAccessor accessor, Chunk chunk)
- Mappings:
Namespace Name Mixin selector official <init>Lcof;<init>(Lbwi;Lclk;)Vintermediary <init>Lnet/minecraft/class_5817;<init>(Lnet/minecraft/class_5138;Lnet/minecraft/class_2791;)Vnamed <init>Lnet/minecraft/world/gen/StructureWeightSampler;<init>(Lnet/minecraft/world/gen/StructureAccessor;Lnet/minecraft/world/chunk/Chunk;)V
-
StructureWeightSampler
private StructureWeightSampler()
-
-
方法详细资料
-
getWeight
protected double getWeight(int x, int y, int z)Gets the weight of the structures near the given position.- Mappings:
Namespace Name Mixin selector official aLcof;a(III)Dintermediary method_33638Lnet/minecraft/class_5817;method_33638(III)Dnamed getWeightLnet/minecraft/world/gen/StructureWeightSampler;getWeight(III)D
-
getMagnitudeWeight
private static double getMagnitudeWeight(int x, int y, int z)- Mappings:
Namespace Name Mixin selector official bLcof;b(III)Dintermediary method_33832Lnet/minecraft/class_5817;method_33832(III)Dnamed getMagnitudeWeightLnet/minecraft/world/gen/StructureWeightSampler;getMagnitudeWeight(III)D
-
getStructureWeight
private static double getStructureWeight(int x, int y, int z)Gets the structure weight from the array from the given position, or 0 if the position is out of bounds.- Mappings:
Namespace Name Mixin selector official cLcof;c(III)Dintermediary method_33641Lnet/minecraft/class_5817;method_33641(III)Dnamed getStructureWeightLnet/minecraft/world/gen/StructureWeightSampler;getStructureWeight(III)D
-
calculateStructureWeight
private static double calculateStructureWeight(int x, int y, int z)Calculates the structure weight for the given position.The weight increases as x and z approach
(0, 0), and positive y values make the weight negative while negative y values make the weight positive.- Mappings:
Namespace Name Mixin selector official dLcof;d(III)Dintermediary method_33642Lnet/minecraft/class_5817;method_33642(III)Dnamed calculateStructureWeightLnet/minecraft/world/gen/StructureWeightSampler;calculateStructureWeight(III)D
-
-