Map tree params (#2350)

This commit is contained in:
apple502j 2021-04-28 22:57:24 +09:00 committed by GitHub
parent 4a9c1c8639
commit f50b55eecf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 108 additions and 1 deletions

View File

@ -5,5 +5,7 @@ CLASS net/minecraft/class_4646 net/minecraft/world/gen/foliage/BlobFoliagePlacer
ARG 1 radius
ARG 2 offset
ARG 3 height
METHOD method_28837 (Lnet/minecraft/class_4646;)Ljava/lang/Integer;
ARG 0 placer
METHOD method_28838 createCodec (Lcom/mojang/serialization/codecs/RecordCodecBuilder$Instance;)Lcom/mojang/datafixers/Products$P3;
ARG 0 builder

View File

@ -7,10 +7,23 @@ CLASS net/minecraft/class_4647 net/minecraft/world/gen/foliage/FoliagePlacer
ARG 2 offset
METHOD method_23448 generate (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_4643;ILnet/minecraft/class_4647$class_5208;III)V
COMMENT This is the main method used to generate foliage.
ARG 7 radius
ARG 1 world
ARG 2 replacer
ARG 3 random
ARG 4 config
ARG 5 trunkHeight
ARG 6 treeNode
ARG 7 foliageHeight
ARG 8 radius
ARG 9 offset
METHOD method_23449 generateSquare (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_4643;Lnet/minecraft/class_2338;IIZ)V
COMMENT Generates a square of leaves with the given radius. Sub-classes can use the method {@code isInvalidForLeaves} to exclude certain positions, such as corners.
ARG 1 world
ARG 2 replacer
ARG 3 random
ARG 4 config
ARG 5 centerPos
ARG 6 radius
ARG 7 y
ARG 8 giantTrunk
METHOD method_23451 isInvalidForLeaves (Ljava/util/Random;IIIIZ)Z
@ -29,6 +42,14 @@ CLASS net/minecraft/class_4647 net/minecraft/world/gen/foliage/FoliagePlacer
ARG 2 trunkHeight
ARG 3 config
METHOD method_27385 generate (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_4643;ILnet/minecraft/class_4647$class_5208;II)V
ARG 1 world
ARG 2 replacer
ARG 3 random
ARG 4 config
ARG 5 trunkHeight
ARG 6 treeNode
ARG 7 foliageHeight
ARG 8 radius
METHOD method_27386 getRandomOffset (Ljava/util/Random;)I
ARG 1 random
METHOD method_27387 isPositionInvalid (Ljava/util/Random;IIIIZ)Z
@ -40,10 +61,17 @@ CLASS net/minecraft/class_4647 net/minecraft/world/gen/foliage/FoliagePlacer
ARG 5 radius
ARG 6 giantTrunk
METHOD method_28843 getType ()Lnet/minecraft/class_4648;
METHOD method_30410 (Lnet/minecraft/class_4647;)Lnet/minecraft/class_6017;
ARG 0 placer
METHOD method_30411 fillFoliagePlacerFields (Lcom/mojang/serialization/codecs/RecordCodecBuilder$Instance;)Lcom/mojang/datafixers/Products$P2;
METHOD method_30412 (Lnet/minecraft/class_4647;)Lnet/minecraft/class_6017;
ARG 0 placer
METHOD method_34359 placeFoliageBlock (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_4643;Lnet/minecraft/class_2338;)V
ARG 0 world
ARG 1 replacer
ARG 2 random
ARG 3 config
ARG 4 pos
CLASS class_5208 TreeNode
COMMENT A point on a tree to generate foliage around
FIELD field_24158 center Lnet/minecraft/class_2338;

View File

@ -5,3 +5,5 @@ CLASS net/minecraft/class_5209 net/minecraft/world/gen/foliage/JungleFoliagePlac
ARG 1 radius
ARG 2 offset
ARG 3 height
METHOD method_28851 (Lnet/minecraft/class_5209;)Ljava/lang/Integer;
ARG 0 placer

View File

@ -5,3 +5,5 @@ CLASS net/minecraft/class_5210 net/minecraft/world/gen/foliage/MegaPineFoliagePl
ARG 1 radius
ARG 2 offset
ARG 3 crownHeight
METHOD method_30414 (Lnet/minecraft/class_5210;)Lnet/minecraft/class_6017;
ARG 0 placer

View File

@ -5,3 +5,5 @@ CLASS net/minecraft/class_4649 net/minecraft/world/gen/foliage/PineFoliagePlacer
ARG 1 radius
ARG 2 offset
ARG 3 height
METHOD method_30416 (Lnet/minecraft/class_4649;)Lnet/minecraft/class_6017;
ARG 0 placer

View File

@ -7,3 +7,7 @@ CLASS net/minecraft/class_5928 net/minecraft/world/gen/foliage/RandomSpreadFolia
ARG 2 offset
ARG 3 foliageHeight
ARG 4 leafPlacementAttempts
METHOD method_34361 (Lnet/minecraft/class_5928;)Ljava/lang/Integer;
ARG 0 placer
METHOD method_34362 (Lnet/minecraft/class_5928;)Lnet/minecraft/class_6017;
ARG 0 placer

View File

@ -5,3 +5,5 @@ CLASS net/minecraft/class_4650 net/minecraft/world/gen/foliage/SpruceFoliagePlac
ARG 1 radius
ARG 2 offset
ARG 3 trunkHeight
METHOD method_30418 (Lnet/minecraft/class_4650;)Lnet/minecraft/class_6017;
ARG 0 placer

View File

@ -8,3 +8,7 @@ CLASS net/minecraft/class_5930 net/minecraft/world/gen/trunk/BendingTrunkPlacer
ARG 3 secondRandomHeight
ARG 4 minHeightForLeaves
ARG 5 bendLength
METHOD method_34372 (Lnet/minecraft/class_5930;)Lnet/minecraft/class_6017;
ARG 0 placer
METHOD method_34374 (Lnet/minecraft/class_5930;)Ljava/lang/Integer;
ARG 0 placer

View File

@ -1,3 +1,12 @@
CLASS net/minecraft/class_5214 net/minecraft/world/gen/trunk/GiantTrunkPlacer
FIELD field_24969 CODEC Lcom/mojang/serialization/Codec;
METHOD method_27399 setLog (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_2338$class_2339;Lnet/minecraft/class_4643;Lnet/minecraft/class_2338;III)V
ARG 0 world
ARG 1 replacer
ARG 2 random
ARG 3 pos
ARG 4 config
ARG 5 startPos
ARG 6 x
ARG 7 y
ARG 8 z

View File

@ -4,7 +4,21 @@ CLASS net/minecraft/class_5212 net/minecraft/world/gen/trunk/LargeOakTrunkPlacer
ARG 1 treeHeight
ARG 2 height
METHOD method_27392 makeBranches (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;ILnet/minecraft/class_2338;Ljava/util/List;Lnet/minecraft/class_4643;)V
ARG 1 world
ARG 2 replacer
ARG 3 random
ARG 4 treeHeight
ARG 5 startPos
ARG 6 branchPositions
ARG 7 config
METHOD method_27393 makeOrCheckBranch (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_2338;Lnet/minecraft/class_2338;ZLnet/minecraft/class_4643;)Z
ARG 1 world
ARG 2 replacer
ARG 3 random
ARG 4 startPos
ARG 5 branchPos
ARG 6 make
ARG 7 config
METHOD method_27394 getLongestSide (Lnet/minecraft/class_2338;)I
ARG 1 offset
METHOD method_27395 getLogAxis (Lnet/minecraft/class_2338;Lnet/minecraft/class_2338;)Lnet/minecraft/class_2350$class_2351;
@ -12,6 +26,10 @@ CLASS net/minecraft/class_5212 net/minecraft/world/gen/trunk/LargeOakTrunkPlacer
ARG 2 branchEnd
METHOD method_27396 shouldGenerateBranch (II)F
COMMENT If the returned value is greater than or equal to 0, a branch will be generated.
ARG 0 treeHeight
ARG 1 height
METHOD method_35374 (Lnet/minecraft/class_2338;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;)Lnet/minecraft/class_2680;
ARG 3 state
CLASS class_5213 BranchPosition
FIELD field_24169 node Lnet/minecraft/class_4647$class_5208;
FIELD field_24170 endY I

View File

@ -9,11 +9,33 @@ CLASS net/minecraft/class_5141 net/minecraft/world/gen/trunk/TrunkPlacer
ARG 3 secondRandomHeight
METHOD method_26991 generate (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;ILnet/minecraft/class_2338;Lnet/minecraft/class_4643;)Ljava/util/List;
COMMENT Generates the trunk blocks and return a list of tree nodes to place foliage around
ARG 1 world
ARG 2 replacer
ARG 3 random
ARG 4 height
ARG 5 startPos
ARG 6 config
METHOD method_26993 getHeight (Ljava/util/Random;)I
ARG 1 random
METHOD method_27400 setToDirt (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_2338;Lnet/minecraft/class_4643;)V
ARG 0 world
ARG 1 replacer
ARG 2 random
ARG 3 pos
ARG 4 config
METHOD method_27401 trySetState (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_2338$class_2339;Lnet/minecraft/class_4643;)V
ARG 0 world
ARG 1 replacer
ARG 2 random
ARG 3 pos
ARG 4 config
METHOD method_27402 getAndSetState (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_2338;Lnet/minecraft/class_4643;Ljava/util/function/Function;)Z
ARG 0 world
ARG 1 replacer
ARG 2 random
ARG 3 pos
ARG 4 config
ARG 5 stateProvider
METHOD method_27403 canGenerate (Lnet/minecraft/class_3746;Lnet/minecraft/class_2338;)Z
ARG 0 world
ARG 1 pos
@ -22,3 +44,15 @@ CLASS net/minecraft/class_5141 net/minecraft/world/gen/trunk/TrunkPlacer
METHOD method_28903 getType ()Lnet/minecraft/class_5142;
METHOD method_28904 fillTrunkPlacerFields (Lcom/mojang/serialization/codecs/RecordCodecBuilder$Instance;)Lcom/mojang/datafixers/Products$P3;
ARG 0 instance
METHOD method_28905 (Lnet/minecraft/class_5141;)Ljava/lang/Integer;
ARG 0 placer
METHOD method_28906 (Lnet/minecraft/class_5141;)Ljava/lang/Integer;
ARG 0 placer
METHOD method_28907 (Lnet/minecraft/class_5141;)Ljava/lang/Integer;
ARG 0 placer
METHOD method_35375 getAndSetState (Lnet/minecraft/class_3746;Ljava/util/function/BiConsumer;Ljava/util/Random;Lnet/minecraft/class_2338;Lnet/minecraft/class_4643;)Z
ARG 0 world
ARG 1 replacer
ARG 2 random
ARG 3 pos
ARG 4 config