spiritfilled Posted November 9, 2021 Posted November 9, 2021 Is there a way of tweaking some vanilla class: I want to, change this code from Level.class (World.class on 1.16.x i think) public abstract class Level extends net.minecraftforge.common.capabilities.CapabilityProvider<Level> implements LevelAccessor, AutoCloseable, net.minecraftforge.common.extensions.IForgeLevel { ... public boolean isRainingAt(BlockPos p_46759_) { if (!this.isRaining()) { return false; } else if (!this.canSeeSky(p_46759_)) { return false; } else if (this.getHeightmapPos(Heightmap.Types.MOTION_BLOCKING, p_46759_).getY() > p_46759_.getY()) { return false; } else { Biome biome = this.getBiome(p_46759_); return biome.getPrecipitation() == Biome.Precipitation.RAIN && biome.getTemperature(p_46759_) >= 0.15F; } } ... } what i want to do is, make the rain stop or start on specific area (or better change climate). Biome's climate settings(temperature, humidity) can be changed, but i think only once, on world generation, I think source: [1.17.1] net.minecraft.world.level; net.minecraft.world.level.biome; net.minecraftforge.event.world.BiomeLoadingEvent; im nowhere near what im trying to do... but if anyone has an idea how to achieve it, or anything similar, any help is appreciated :3 can the class be replaced with extention??? Quote
spiritfilled Posted November 9, 2021 Author Posted November 9, 2021 hi, it's u againĀ š so i shouldn't change it... (regardless of compatibility with other mods) how about anything with similar result, any idea... im trying to add monsoon and season Quote
than00ber1 Posted November 9, 2021 Posted November 9, 2021 Mixins?Ā https://github.com/SpongePowered/Mixin/wiki/Introduction-to-Mixins---Understanding-Mixin-Architecture#2-through-the-looking-glass Quote
spiritfilled Posted November 9, 2021 Author Posted November 9, 2021 19 minutes ago, diesieben07 said: Not in a supported way. hi, it's u againĀ š so i shouldn't change it... (regardless of compatibility with other mods) how about anything with similar result, any idea... im trying to add monsoon and season Quote
spiritfilled Posted November 9, 2021 Author Posted November 9, 2021 3 minutes ago, than00ber1 said: Mixins?Ā https://github.com/SpongePowered/Mixin/wiki/Introduction-to-Mixins---Understanding-Mixin-Architecture#2-through-the-looking-glass ohhhhh look interesting. ill read first. anyway thanks! Quote
spiritfilled Posted November 9, 2021 Author Posted November 9, 2021 3 hours ago, diesieben07 said: Mixins / Coremods are not a supported practice here. oh, oki. thanks anyways Quote
Luis_ST Posted November 9, 2021 Posted November 9, 2021 you could ask on the Forge discord serverĀ in the channel #non-api-modding (there are the experts about Mixins/Coremods) Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.