Remove most of PseudoRandom, a few minor cleaning changes, and an upstream change

This commit is contained in:
matt
2019-03-26 13:41:09 -04:00
parent 0d88a6bce2
commit 3420b8329b
15 changed files with 128 additions and 147 deletions

View File

@ -1,11 +1,10 @@
package com.boydti.fawe.util;
import com.boydti.fawe.object.PseudoRandom;
import com.sk89q.worldedit.world.block.BlockType;
import com.sk89q.worldedit.world.block.BlockTypes;
import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap;
import java.io.FileNotFoundException;
import java.util.concurrent.ThreadLocalRandom;
public class RandomTextureUtil extends CachedTextureUtil {
@ -33,9 +32,10 @@ public class RandomTextureUtil extends CachedTextureUtil {
private int random(int i) {
if (i < 0) {
return -PseudoRandom.random.nextInt((-i));
int i1 = (-i);
return -ThreadLocalRandom.current().nextInt(i1);
} else {
return PseudoRandom.random.nextInt(i);
return ThreadLocalRandom.current().nextInt(i);
}
}