Skip to content

Commit

Permalink
Minor fix for biome uniforms
Browse files Browse the repository at this point in the history
  • Loading branch information
IMS212 committed Nov 19, 2023
1 parent 106ae58 commit b748204
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ private ShaderProperties() {
// TODO: Is there a better solution than having ShaderPack pass a root path to ShaderProperties to be able to read textures?
public ShaderProperties(String contents, ShaderPackOptions shaderPackOptions, Iterable<StringPair> environmentDefines, Iterable<StringPair> replacements) {
for (StringPair pair : replacements) {
contents = contents.replace(pair.getKey(), pair.getValue());
contents = contents.replaceAll("\\b" + pair.getKey() + "\\b", pair.getValue());
}

String preprocessedContents = PropertiesPreprocessor.preprocessSource(contents, shaderPackOptions, environmentDefines);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ public void addVariable(String type, String name, String expression, boolean isU
ExpressionElement ast = Parser.parse(expression, IrisOptions.options);
variables.put(name, new Variable(parsedType, name, ast, isUniform));
} catch (Exception e) {
Iris.logger.warn("Failed to parse custom variable/uniform", e);
Iris.logger.warn("Failed to parse custom variable/uniform " + name + " with expression " + expression, e);
}
}

Expand Down

0 comments on commit b748204

Please sign in to comment.