Package net.minecraft.world.gen.random
Class Xoroshiro128PlusPlusRandom
java.lang.Object
net.minecraft.world.gen.random.Xoroshiro128PlusPlusRandom
- All Implemented Interfaces:
AbstractRandom
Xoroshiro128++ based pseudo random number generator.
- Implementation Note:
- The actual implementation can be found on
Xoroshiro128PlusPlusRandomImpl
. - Mappings:
Namespace Name official ctu
intermediary net/minecraft/class_6677
named net/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final double
private static final float
private final GaussianGenerator
private Xoroshiro128PlusPlusRandomImpl
-
Constructor Summary
ConstructorDescriptionXoroshiro128PlusPlusRandom
(long seed) Xoroshiro128PlusPlusRandom
(long seedLo, long seedHi) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.world.gen.random.AbstractRandom
nextBetween
-
Field Details
-
FLOAT_MULTIPLIER
private static final float FLOAT_MULTIPLIER- See Also:
- Mappings:
Namespace Name Mixin selector official a
Lctu;a:F
intermediary field_35148
Lnet/minecraft/class_6677;field_35148:F
named FLOAT_MULTIPLIER
Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom;FLOAT_MULTIPLIER:F
-
DOUBLE_MULTIPLIER
private static final double DOUBLE_MULTIPLIER- See Also:
- Mappings:
Namespace Name Mixin selector official b
Lctu;b:D
intermediary field_35149
Lnet/minecraft/class_6677;field_35149:D
named DOUBLE_MULTIPLIER
Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom;DOUBLE_MULTIPLIER:D
-
implementation
- Mappings:
Namespace Name Mixin selector official c
Lctu;c:Lctt;
intermediary field_35150
Lnet/minecraft/class_6677;field_35150:Lnet/minecraft/class_6676;
named implementation
Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom;implementation:Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandomImpl;
-
gaussianGenerator
- Mappings:
Namespace Name Mixin selector official d
Lctu;d:Lcsw;
intermediary field_35151
Lnet/minecraft/class_6677;field_35151:Lnet/minecraft/class_6672;
named gaussianGenerator
Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom;gaussianGenerator:Lnet/minecraft/world/gen/random/GaussianGenerator;
-
-
Constructor Details
-
Xoroshiro128PlusPlusRandom
public Xoroshiro128PlusPlusRandom(long seed) - Mappings:
Namespace Name Mixin selector official <init>
Lctu;<init>(J)V
intermediary <init>
Lnet/minecraft/class_6677;<init>(J)V
named <init>
Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom;<init>(J)V
-
Xoroshiro128PlusPlusRandom
public Xoroshiro128PlusPlusRandom(long seedLo, long seedHi) - Mappings:
Namespace Name Mixin selector official <init>
Lctu;<init>(JJ)V
intermediary <init>
Lnet/minecraft/class_6677;<init>(JJ)V
named <init>
Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom;<init>(JJ)V
-
-
Method Details
-
derive
- Specified by:
derive
in interfaceAbstractRandom
- Mappings:
Namespace Name Mixin selector official a
Lcti;a()Lcti;
intermediary method_38420
Lnet/minecraft/class_5819;method_38420()Lnet/minecraft/class_5819;
named derive
Lnet/minecraft/world/gen/random/AbstractRandom;derive()Lnet/minecraft/world/gen/random/AbstractRandom;
-
createRandomDeriver
- Specified by:
createRandomDeriver
in interfaceAbstractRandom
- Mappings:
Namespace Name Mixin selector official b
Lcti;b()Lcth;
intermediary method_38421
Lnet/minecraft/class_5819;method_38421()Lnet/minecraft/class_6574;
named createRandomDeriver
Lnet/minecraft/world/gen/random/AbstractRandom;createRandomDeriver()Lnet/minecraft/world/gen/random/RandomDeriver;
-
setSeed
public void setSeed(long seed) - Specified by:
setSeed
in interfaceAbstractRandom
- Mappings:
Namespace Name Mixin selector official setSeed
Lcti;setSeed(J)V
intermediary setSeed
Lnet/minecraft/class_5819;setSeed(J)V
named setSeed
Lnet/minecraft/world/gen/random/AbstractRandom;setSeed(J)V
-
nextInt
public int nextInt()- Specified by:
nextInt
in interfaceAbstractRandom
-
nextInt
public int nextInt(int bound) - Specified by:
nextInt
in interfaceAbstractRandom
- Mappings:
Namespace Name Mixin selector official nextInt
Lcti;nextInt(I)I
intermediary nextInt
Lnet/minecraft/class_5819;nextInt(I)I
named nextInt
Lnet/minecraft/world/gen/random/AbstractRandom;nextInt(I)I
-
nextLong
public long nextLong()- Specified by:
nextLong
in interfaceAbstractRandom
-
nextBoolean
public boolean nextBoolean()- Specified by:
nextBoolean
in interfaceAbstractRandom
-
nextFloat
public float nextFloat()- Specified by:
nextFloat
in interfaceAbstractRandom
-
nextDouble
public double nextDouble()- Specified by:
nextDouble
in interfaceAbstractRandom
-
nextGaussian
public double nextGaussian()- Specified by:
nextGaussian
in interfaceAbstractRandom
-
skip
public void skip(int count) - Specified by:
skip
in interfaceAbstractRandom
- Mappings:
Namespace Name Mixin selector official b
Lcti;b(I)V
intermediary method_33650
Lnet/minecraft/class_5819;method_33650(I)V
named skip
Lnet/minecraft/world/gen/random/AbstractRandom;skip(I)V
-
next
private long next(int bits) Returnsbits
upper bits of random value.- Returns:
bits
upper bits of random value- Implementation Note:
- In Xoroshiro128++, the lower bits have to be discarded in order to ensure proper randomness. For example, to obtain a double, the upper 53 bits, instead of the lower 53 bits.
- Mappings:
Namespace Name Mixin selector official a
Lctu;a(I)J
intermediary method_39008
Lnet/minecraft/class_6677;method_39008(I)J
named next
Lnet/minecraft/world/gen/random/Xoroshiro128PlusPlusRandom;next(I)J
-