Skip to content

Commit

Permalink
Fixed crash on world load with Nothirium
Browse files Browse the repository at this point in the history
  • Loading branch information
Desoroxxx committed Sep 12, 2023
1 parent 7131f9b commit 1f7e9f3
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 deletions.
6 changes: 6 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project follows to [Ragnarök Versioning Convention](https://shor.cz/ragnarok_versioning_convention).

## Alfheim Version 1.0.2 Changelog - 2023-09-12

### Fixed

- Fixed crash on world load with Nothirium

## Alfheim Version 1.0.1 Changelog - 2023-09-08

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ org.gradle.daemon = true
# Mod Constants
# Versioning must follow Ragnarök versioning convention: https://shor.cz/ragnarok_versioning_convention
id = alfheim
version = 1.0.1
version = 1.0.2
3 changes: 3 additions & 0 deletions src/main/java/dev/redstudio/alfheim/Alfheim.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package dev.redstudio.alfheim;

import net.minecraftforge.fml.common.Loader;
import net.minecraftforge.fml.common.Mod;

import static dev.redstudio.alfheim.utils.ModReference.ID;
Expand All @@ -18,4 +19,6 @@
public final class Alfheim {

public static final int FLAG_COUNT = 32; // 2 light types * 4 directions * 2 halves * (inwards + outwards)

public static final boolean IS_NOTHIRIUM_LOADED = Loader.isModLoaded("nothirium");
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
import java.util.Iterator;
import java.util.Set;

import static dev.redstudio.alfheim.Alfheim.IS_NOTHIRIUM_LOADED;

/**
* @author Luna Lage (Desoroxxx)
* @since 1.0
Expand Down Expand Up @@ -50,7 +52,7 @@ private boolean disableVanillaLightUpdates(final Set<BlockPos> instance) {
*/
@Override
public void alfheim$processLightUpdates() {
if (setLightUpdates.isEmpty() || renderDispatcher.hasNoFreeRenderBuilders())
if (setLightUpdates.isEmpty() || (!IS_NOTHIRIUM_LOADED && renderDispatcher.hasNoFreeRenderBuilders()))
return;

final Iterator<BlockPos> iterator = setLightUpdates.iterator();
Expand Down

0 comments on commit 1f7e9f3

Please sign in to comment.