Skip to content

Commit 74e665f

Browse files
committed
Merge remote-tracking branch 'origin/1.20.5/dev' into 1.21/dev
# Conflicts: # build.gradle # gradle.properties # src/main/java/me/pepperbell/continuity/client/properties/BaseCtmProperties.java # src/main/java/me/pepperbell/continuity/client/util/biome/BiomeRetriever.java
2 parents f692392 + aaf9b15 commit 74e665f

31 files changed

+251
-184
lines changed

.github/workflows/build.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v4
10-
- name: Validate Gradle wrapper
11-
uses: gradle/wrapper-validation-action@v2
12-
- name: Set up JDK 17
10+
- name: Set up Java
1311
uses: actions/setup-java@v4
1412
with:
1513
distribution: temurin
1614
java-version: 21
1715
check-latest: true
16+
- name: Setup Gradle
17+
uses: gradle/actions/setup-gradle@v5
1818
- name: Build artifacts
1919
run: ./gradlew build --stacktrace
2020
- name: Upload artifacts

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
# Continuity
22

3-
Continuity is a Fabric mod that allows resource packs that use the OptiFine connected textures format, OptiFine emissive textures format (only for blocks and item models), or OptiFine custom block layers format to work without OptiFine.
3+
Continuity is a Minecraft mod that allows resource packs that use the OptiFine connected textures format, OptiFine emissive textures format (only for blocks and item models), or OptiFine custom block layers format to work without OptiFine.
44

5-
Continuity depends on Fabric API and is client-side only. It includes two built-in resource packs. The Default Connected Textures pack provides connected textures for glass, sandstone, and bookshelves, similar to the built-in connected textures provided by OptiFine. The Glass Pane Culling Fix pack culls faces between vertically stacked glass panes to make them look seamless with connected textures.
5+
Continuity is client-side only and includes two built-in resource packs. The Default Connected Textures pack provides connected textures for glass, sandstone, and bookshelves, similar to the built-in connected textures provided by OptiFine. The Glass Pane Culling Fix pack culls faces between vertically stacked glass panes to make them look seamless with connected textures.
66

77
Formally, Continuity implements the Continuity connected textures specification, Continuity emissive textures specification, and Continuity custom block layers specification. All of these are extensions of the corresponding OptiFine specification and were created to provide more features to resource pack authors. The documentation for the Continuity specifications can be found at the [Continuity wiki](https://github.com/PepperCode1/Continuity/wiki).
88

9-
An official Forge version of Continuity is not planned at this time due to major technical differences between the Fabric and Forge APIs. An official Forge version of Continuity may be considered if these differences are minimized, possibly via the use of libraries.
9+
Continuity is developed as a Fabric mod and is recommended to be used with Fabric. However, [Connector](https://github.com/Sinytra/Connector) and [Forgified Fabric API](https://github.com/Sinytra/ForgifiedFabricAPI) allow Continuity to work well on other mod loaders such as NeoForge and Forge. Releases are made on CurseForge and Modrinth that are marked as working with these mod loaders; these releases contain the same code as equivalent releases for Fabric, but with additional metadata to declare Connector and Forgified Fabric API as dependencies. An official NeoForge version of Continuity that does not require Forgified Fabric API is not planned at this time due to major technical differences between the Fabric and NeoForge APIs.
1010

1111
### Links
1212

gradle.properties

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,17 @@ org.gradle.jvmargs = -Xmx1G
33
org.gradle.parallel = true
44

55
# Fabric Properties
6-
loom_version = 1.6.11
6+
loom_version = 1.12.7
77
minecraft_version = 1.21
88
yarn_mappings = 1.21+build.1
9-
loader_version = 0.15.11
9+
loader_version = 0.17.3
1010

1111
# Mod Properties
12-
mod_version = 3.0.0
12+
mod_version = 3.0.1
1313
mod_minecraft_version = 1.21
1414
maven_group = me.pepperbell
1515
archives_base_name = continuity
1616

1717
# Dependencies
1818
fabric_version = 0.100.1+1.21
19-
modmenu_version = 11.0.0-beta.1
19+
modmenu_version = 11.0.3

gradle/wrapper/gradle-wrapper.jar

311 Bytes
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

gradlew

Lines changed: 7 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gradlew.bat

Lines changed: 4 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main/java/me/pepperbell/continuity/client/mixin/BlockModelsMixin.java

Lines changed: 0 additions & 17 deletions
This file was deleted.

src/main/java/me/pepperbell/continuity/client/model/CtmBakedModel.java

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public void emitBlockQuads(BlockRenderView blockView, BlockState state, BlockPos
6565
// especially if there is an actual use case for it.
6666
BlockState appearanceState = state.getAppearance(blockView, pos, Direction.DOWN, state, pos);
6767

68-
quadTransform.prepare(blockView, appearanceState, state, pos, randomSupplier, context, ContinuityConfig.INSTANCE.useManualCulling.get(), getSliceFunc(appearanceState));
68+
quadTransform.prepare(blockView, appearanceState, state, pos, randomSupplier.get().nextLong(), context, ContinuityConfig.INSTANCE.useManualCulling.get(), getSliceFunc(appearanceState));
6969

7070
context.pushTransform(quadTransform);
7171
super.emitBlockQuads(blockView, state, pos, randomSupplier, context);
@@ -102,12 +102,21 @@ protected Function<Sprite, QuadProcessors.Slice> getSliceFunc(BlockState state)
102102

103103
protected static class CtmQuadTransform implements RenderContext.QuadTransform {
104104
protected final ProcessingContextImpl processingContext = new ProcessingContextImpl();
105+
protected final Supplier<Random> randomSupplier = new Supplier<>() {
106+
private final Random random = Random.createLocal();
107+
108+
@Override
109+
public Random get() {
110+
random.setSeed(randomSeed);
111+
return random;
112+
}
113+
};
105114

106115
protected BlockRenderView blockView;
107116
protected BlockState appearanceState;
108117
protected BlockState state;
109118
protected BlockPos pos;
110-
protected Supplier<Random> randomSupplier;
119+
protected long randomSeed;
111120
protected RenderContext renderContext;
112121
protected boolean useManualCulling;
113122
protected Function<Sprite, QuadProcessors.Slice> sliceFunc;
@@ -156,12 +165,12 @@ public boolean isActive() {
156165
return active;
157166
}
158167

159-
public void prepare(BlockRenderView blockView, BlockState appearanceState, BlockState state, BlockPos pos, Supplier<Random> randomSupplier, RenderContext renderContext, boolean useManualCulling, Function<Sprite, QuadProcessors.Slice> sliceFunc) {
168+
public void prepare(BlockRenderView blockView, BlockState appearanceState, BlockState state, BlockPos pos, long randomSeed, RenderContext renderContext, boolean useManualCulling, Function<Sprite, QuadProcessors.Slice> sliceFunc) {
160169
this.blockView = blockView;
161170
this.appearanceState = appearanceState;
162171
this.state = state;
163172
this.pos = pos;
164-
this.randomSupplier = randomSupplier;
173+
this.randomSeed = randomSeed;
165174
this.renderContext = renderContext;
166175
this.useManualCulling = useManualCulling;
167176
this.sliceFunc = sliceFunc;
@@ -176,7 +185,6 @@ public void reset() {
176185
appearanceState = null;
177186
state = null;
178187
pos = null;
179-
randomSupplier = null;
180188
renderContext = null;
181189
useManualCulling = false;
182190
sliceFunc = null;

src/main/java/me/pepperbell/continuity/client/model/EmissiveBakedModel.java

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public void emitBlockQuads(BlockRenderView blockView, BlockState state, BlockPos
6666
}
6767

6868
MeshBuilder meshBuilder = container.meshBuilder;
69-
quadTransform.prepare(meshBuilder.getEmitter(), blockView, state, pos, context, ContinuityConfig.INSTANCE.useManualCulling.get());
69+
quadTransform.prepare(meshBuilder.getEmitter(), state, context, ContinuityConfig.INSTANCE.useManualCulling.get());
7070

7171
context.pushTransform(quadTransform);
7272
super.emitBlockQuads(blockView, state, pos, randomSupplier, context);
@@ -120,9 +120,7 @@ public boolean isVanillaAdapter() {
120120

121121
protected static class EmissiveBlockQuadTransform implements RenderContext.QuadTransform {
122122
protected QuadEmitter emitter;
123-
protected BlockRenderView blockView;
124123
protected BlockState state;
125-
protected BlockPos pos;
126124
protected RenderContext renderContext;
127125
protected boolean useManualCulling;
128126

@@ -177,11 +175,9 @@ public boolean didEmit() {
177175
return didEmit;
178176
}
179177

180-
public void prepare(QuadEmitter emitter, BlockRenderView blockView, BlockState state, BlockPos pos, RenderContext renderContext, boolean useManualCulling) {
178+
public void prepare(QuadEmitter emitter, BlockState state, RenderContext renderContext, boolean useManualCulling) {
181179
this.emitter = emitter;
182-
this.blockView = blockView;
183180
this.state = state;
184-
this.pos = pos;
185181
this.renderContext = renderContext;
186182
this.useManualCulling = useManualCulling;
187183

@@ -193,9 +189,7 @@ public void prepare(QuadEmitter emitter, BlockRenderView blockView, BlockState s
193189

194190
public void reset() {
195191
emitter = null;
196-
blockView = null;
197192
state = null;
198-
pos = null;
199193
renderContext = null;
200194
useManualCulling = false;
201195

0 commit comments

Comments
 (0)