9
0
mirror of https://github.com/VolmitSoftware/Iris.git synced 2025-12-27 11:09:06 +00:00

Biome specific generators

This commit is contained in:
Daniel Mills
2020-01-17 09:19:41 -05:00
parent 165517608d
commit 451eca0aa9
12 changed files with 427 additions and 210 deletions

View File

@@ -57,7 +57,7 @@ public class CommandIris implements CommandExecutor
{
IrisGenerator g = (IrisGenerator) w.getGenerator();
IrisBiome b = null;
for(IrisBiome i : g.getLoadedBiomes())
for(IrisBiome i : g.getDimension().getBiomes())
{
if(args[1].toLowerCase().equals(i.getName().toLowerCase().replaceAll("\\Q \\E", "_")))
{
@@ -81,7 +81,7 @@ public class CommandIris implements CommandExecutor
int x = (int) ((int) (29999983 / 1.2) * Math.random());
int z = (int) ((int) (29999983 / 1.2) * Math.random());
if(g.getBiome(x, z).equals(b))
if(g.getBiome((int) g.getOffsetX(x), (int) g.getOffsetZ(z)).equals(b))
{
f = true;
@@ -90,11 +90,11 @@ public class CommandIris implements CommandExecutor
p.teleport(w.getHighestBlockAt(x, z).getLocation());
break;
}
else
{
t++;
if(t > 30)
{
msg(sender, "Checked 30 " + b.getName() + " bearing chunks. All of them were underwater. Try Again!");