Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
squid233 committed Jun 2, 2024
1 parent 49c6ea0 commit 1954ce1
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 6 deletions.
3 changes: 2 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ val commonsPoolVersion: String by rootProject
val gsonVersion: String by rootProject
val jomlVersion: String by rootProject
val logbackVersion: String by rootProject
val reactorVersion: String by rootProject

class GameModule(
val artifactId: String,
Expand Down Expand Up @@ -137,7 +138,7 @@ subprojects {
implementation("ch.qos.logback:logback-classic:$logbackVersion")
implementation("com.google.code.gson:gson:$gsonVersion")
implementation("org.apache.commons:commons-pool2:$commonsPoolVersion")
implementation(platform("io.projectreactor:reactor-bom:2023.0.6"))
implementation(platform("io.projectreactor:reactor-bom:$reactorVersion"))
implementation("io.projectreactor:reactor-core")
implementation("io.projectreactor.addons:reactor-pool")
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
import freeworld.util.Logging;
import freeworld.world.block.BlockType;
import freeworld.world.entity.Entity;
import org.joml.Matrix4f;
import org.slf4j.Logger;
import overrungl.opengl.GL10C;

Expand All @@ -47,8 +46,6 @@ public final class GameRenderer implements GLResource {
private final Freeworld client;
private GLProgram positionColorProgram;
private GLProgram positionColorTexProgram;
@Deprecated
private final Matrix4f modelMatrix = new Matrix4f();
public static final Identifier TEX_DIRT = Identifier.ofBuiltin("texture/block/dirt.png");
public static final Identifier TEX_GRASS_BLOCK = Identifier.ofBuiltin("texture/block/grass_block.png");
public static final Identifier TEX_STONE = Identifier.ofBuiltin("texture/block/stone.png");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public final class WorldRenderer implements GLResource, WorldListener {
private final World world;
private final Scheduler scheduler = Schedulers.newParallel("WorldRenderer");
private final Pool<DefaultVertexBuilder> vertexBuilderPool = PoolBuilder
.from(Mono.fromCallable(WorldRenderer::createVertexBuilder).subscribeOn(scheduler))
.from(Mono.fromSupplier(WorldRenderer::createVertexBuilder).subscribeOn(scheduler))
.buildPool();
private final Map<ChunkPos, ClientChunk> chunks = new ConcurrentHashMap<>(RENDER_CHUNK_COUNT);
private final Disposable chunkGC;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public ClientChunk(World world, WorldRenderer worldRenderer, int x, int y, int z
this.state = new State(worldRenderer.gameRenderer().client().gl());
this.cleanable = CLEANER.register(this, state);
this.dataFlux = worldRenderer.vertexBuilderPool()
.withPoolable(vertexBuilder -> Mono.fromCallable(() -> ChunkCompiler.compile(
.withPoolable(vertexBuilder -> Mono.fromSupplier(() -> ChunkCompiler.compile(
vertexBuilder,
worldRenderer.gameRenderer().blockRenderer(),
this
Expand Down

0 comments on commit 1954ce1

Please sign in to comment.