Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
80cc009
Create mixin and module configs variables for natural textures
Kynake Dec 12, 2025
02baed8
Add mixin class needed for Natural textures.
Kynake Dec 15, 2025
441ba7e
Pass Quad side when applying natural texture
Kynake Dec 17, 2025
25d2631
Add WIP quad UV rotation
Kynake Dec 17, 2025
13d5d49
Add formulas to fix the UV aspect ratio on 90 degree rotations
Kynake Dec 18, 2025
e575c7e
Simplify UV rotation aspect formula
Kynake Dec 20, 2025
a233c25
Separate rotate and mirror UV methods
Kynake Dec 20, 2025
1285420
Rename NaturalTextures to NaturalTexturesEngine
Kynake Dec 20, 2025
04e1677
Crete class to describe a natural texture configuration
Kynake Dec 21, 2025
a26714b
Implement loading configs from Natural textures file
Kynake Dec 21, 2025
7610819
Randomize natural texture UV based on block coords, and side
Kynake Dec 22, 2025
77341ba
Implement custom natural.properties parser to allow for ':' in resour…
Kynake Dec 22, 2025
271283c
rename Natural Texture resource loader method and refactor associated…
Kynake Dec 23, 2025
97535e0
Add warning log when unable to parse a line from natural.properties
Kynake Dec 24, 2025
f806200
Refactor Axis and Side into common packages
Kynake Dec 26, 2025
918cb7c
Replace ForgeDirection refs for Side in natural textures code
Kynake Dec 26, 2025
4429d67
Set natural textures as disabled by default
Kynake Dec 26, 2025
20923e4
Group rotation code closer together
Kynake Dec 28, 2025
394d25a
Improve natural textures random hasher:
Kynake Dec 28, 2025
b51e82b
Partial work on Vine Block natural textures: East and West sides
Kynake Dec 28, 2025
4ce96f7
Implement natural textures for vine block: North, South and Bottom faces
Kynake Dec 29, 2025
0e135de
Remove Block argument from natural texture applicator
Kynake Dec 29, 2025
e722dc2
Add natural textures capabilities to crossed squares rendering
Kynake Dec 29, 2025
72297f0
Add natural textures capabilities to crop blocks
Kynake Dec 29, 2025
fbbcb41
Parse all resourcepacks when creating list of natural textures
Kynake Jan 1, 2026
ef7fafa
Create extra config class to store settings not directly to do with m…
Kynake Jan 1, 2026
1bbb9be
Use new config for stacking natural textures when parsing them from r…
Kynake Jan 1, 2026
80b5043
Add default natural textures config to vanilla assets
Kynake Jan 2, 2026
fd0b4a2
Add default natural textures config to vanilla assets
Kynake Jan 2, 2026
1a2c4a9
Add default natural textures for EFR added blocks
Kynake Jan 2, 2026
e4bc48f
Add Natural Textures description to template file
Kynake Jan 2, 2026
d78645e
Add missing config comments to natural texture configs
Kynake Jan 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
/*
* Right Proper MCPatcher
*
* Copyright (C) 2025 FalsePattern
* All Rights Reserved
*
* The above copyright notice and this permission notice shall be included
* in all copies or substantial portions of the Software.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, only version 3 of the License.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/

package com.falsepattern.mcpatcher.internal.config;

import com.falsepattern.lib.config.Config;
import com.falsepattern.lib.config.ConfigurationManager;
import com.falsepattern.mcpatcher.Tags;
import lombok.NoArgsConstructor;

@Config.Comment("Additional Runtime Configurations")
@Config.LangKey
@Config(modid = Tags.MOD_ID,
category = "02_extras")
@NoArgsConstructor
public final class ExtraConfig {
//@formatter:off
@Config.Comment({"Disable this if you don't want Natural Textures configuration files from multiple resource packs to 'stack' on top of each other in order of priority.",
"If true, the total set of Natural Textures will be created using all resource packs in the chain.",
"If false, only the highest priority 'natural.properties' file will be used."})
@Config.LangKey
@Config.Name("naturalTexturesStack")
@Config.DefaultBoolean(true)
public static boolean naturalTexturesStack;
//@formatter:on

// region Init
static {
ConfigurationManager.selfInit();
ModuleConfig.init();
}

/**
* This is here to make the static initializer run
*/
public static void init() {

}
// endregion
}
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ private static Class<?>[] getConfigClasses() {
val result = new ArrayList<Class<?>>();
result.add(ModuleConfig.class);
result.add(MixinConfig.class);
result.add(ExtraConfig.class);
return result.toArray(new Class<?>[0]);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,13 @@ public final class MixinConfig {
@Config.DefaultBoolean(true)
public static boolean connectedTexturesMixins;

@Config.Comment({"Disable this if you don't want natural texture mixins to land.",
"This is required for naturalTextures."})
@Config.LangKey
@Config.Name("naturalTexturesMixins")
@Config.DefaultBoolean(true)
public static boolean naturalTexturesMixins;

@Config.Comment({"Disable this if you don't want better glass mixins to land.",
"This is required for betterGlass."})
@Config.LangKey
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,13 @@ public final class ModuleConfig {
@Config.DefaultBoolean(true)
public static boolean connectedTextures;

@Config.Comment({"Runtime toggle for natural textures.",
"Requires naturalTexturesMixins enabled."})
@Config.LangKey
@Config.Name("naturalTextures")
@Config.DefaultBoolean(false)
public static boolean naturalTextures;

@Config.Comment({"Allow regular glass blocks, glass panes, and beacon glass to have semi-transparent textures.",
"Requires betterGlassMixins enabled."})
@Config.LangKey
Expand All @@ -67,6 +74,10 @@ public static boolean isConnectedTexturesEnabled() {
return MixinConfig.connectedTexturesMixins && connectedTextures;
}

public static boolean isNaturalTexturesEnabled() {
return MixinConfig.naturalTexturesMixins && naturalTextures;
}

public static boolean isBetterGlassEnabled() {
return MixinConfig.betterGlassMixins && betterGlass;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,11 @@ public enum Mixin implements IMixins {
() -> MixinConfig.connectedTexturesMixins && MixinConfig.resourcePackOverlayMixins,
client("ctm.TextureMapMixin_Overlay")),

NaturalTextures(Phase.EARLY,
() -> MixinConfig.naturalTexturesMixins,
client("natural.RenderBlocksMixin",
"natural.TextureMapMixin")),

RandomMobs(Phase.EARLY,
() -> MixinConfig.randomMobsMixins,
client("mob.EntityMixin",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
import com.falsepattern.mcpatcher.internal.config.ModuleConfig;
import com.falsepattern.mcpatcher.internal.modules.ctm.CTMEngine;
import com.falsepattern.mcpatcher.internal.modules.ctm.PaneRenderHelper;
import com.falsepattern.mcpatcher.internal.modules.ctm.Side;
import com.falsepattern.mcpatcher.internal.modules.common.Side;
import com.llamalad7.mixinextras.injector.wrapoperation.Operation;
import com.llamalad7.mixinextras.injector.wrapoperation.WrapOperation;
import com.llamalad7.mixinextras.sugar.Local;
Expand Down
Loading