-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove hardcoded biome ID limit in this mod
- Loading branch information
Showing
3 changed files
with
35 additions
and
0 deletions.
There are no files selected for viewing
14 changes: 14 additions & 0 deletions
14
src/main/java/org/dimdev/jeid/mixin/modsupport/biometweaker/MixinBiomeColorMappings.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package org.dimdev.jeid.mixin.modsupport.biometweaker; | ||
|
||
import me.superckl.biometweaker.util.BiomeColorMappings; | ||
import org.spongepowered.asm.mixin.Mixin; | ||
import org.spongepowered.asm.mixin.injection.Constant; | ||
import org.spongepowered.asm.mixin.injection.ModifyConstant; | ||
|
||
@Mixin(BiomeColorMappings.class) | ||
public class MixinBiomeColorMappings { | ||
@ModifyConstant(method = "getColorForBiome", constant = @Constant(intValue = 0xFF), remap = false) | ||
private static int getBitMask(int oldValue) { | ||
return 0xFFFFFFFF; | ||
} | ||
} |
19 changes: 19 additions & 0 deletions
19
src/main/java/org/dimdev/jeid/mixin/modsupport/biometweaker/MixinBiomeHelper.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package org.dimdev.jeid.mixin.modsupport.biometweaker; | ||
|
||
import me.superckl.biometweaker.util.BiomeHelper; | ||
import org.spongepowered.asm.mixin.Mixin; | ||
import org.spongepowered.asm.mixin.injection.Constant; | ||
import org.spongepowered.asm.mixin.injection.ModifyConstant; | ||
|
||
@Mixin(BiomeHelper.class) | ||
public class MixinBiomeHelper { | ||
@ModifyConstant(method = "getNextFreeBiomeId", constant = @Constant(intValue = 0xFF), remap = false) | ||
private static int getMaxBiomeId(int oldValue) { | ||
return 0xFFFFFFFF; | ||
} | ||
|
||
@ModifyConstant(method = "getNextFreeBiomeId", constant = @Constant(intValue = 0x100), remap = false) | ||
private static int getLoopUpperLimit(int oldValue) { | ||
return 0xEFFFFFFF; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters