mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-04-05 23:36:12 +00:00
Fixed
This commit is contained in:
@@ -67,21 +67,14 @@ public class IrisDimension
|
||||
private GList<IrisBiome> biomesFromArray(JSONArray a) throws JSONException, IOException
|
||||
{
|
||||
GList<IrisBiome> b = new GList<>();
|
||||
TaskExecutor t = new TaskExecutor(Runtime.getRuntime().availableProcessors() * 2, Thread.MIN_PRIORITY, "Biome Loader");
|
||||
TaskGroup g = t.startWork();
|
||||
for(int i = 0; i < a.length(); i++)
|
||||
{
|
||||
int ii = i;
|
||||
|
||||
g.queue(() ->
|
||||
{
|
||||
IrisBiome bb = Iris.getController(PackController.class).loadBiome(a.getString(ii));
|
||||
Iris.getController(PackController.class).registerBiome(a.getString(ii), bb);
|
||||
b.add(bb);
|
||||
});
|
||||
IrisBiome bb = Iris.getController(PackController.class).loadBiome(a.getString(ii));
|
||||
Iris.getController(PackController.class).registerBiome(a.getString(ii), bb);
|
||||
b.add(bb);
|
||||
}
|
||||
g.execute();
|
||||
t.close();
|
||||
return b;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user