mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-10-20 23:36:52 +00:00
Fixed
This commit is contained in:
1 parent
1b9c7d48e4
commit
445ce46357
13 files changed
+391
-109
No files matched your search
@@ -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