• Recently Browsing

    No registered users viewing this page.

  • Posts

    • Hello together On testing my own World Ore Gen Geatures i've fond an Error and i don't understand how this Error can Happens.   When World is be createted the function place in Any Feature will bee called. When i Configured my Feature with a  placement with bottom-offset top-offset an maxHeigt. Wenn Place is called it is possible to get an y-value with is lower then bottomOffset. On serching i've fond the Class placement witch is called befor Feture starts.                  package net.minecraft.world.gen.placement; import com.mojang.datafixers.Dynamic; import java.util.Random; import java.util.function.Function; import java.util.stream.IntStream; import java.util.stream.Stream; import net.minecraft.util.math.BlockPos; public class HeightBiasedRange extends SimplePlacement<CountRangeConfig> {    public HeightBiasedRange(Function<Dynamic<?>, ? extends CountRangeConfig> p_i51388_1_) {       super(p_i51388_1_);    }    public Stream<BlockPos> getPositions(Random random, CountRangeConfig p_212852_2_, BlockPos pos) {       return IntStream.range(0, p_212852_2_.count).mapToObj((p_227436_3_) -> {          int i = random.nextInt(16) + pos.getX();          int j = random.nextInt(16) + pos.getZ();          int k = random.nextInt(random.nextInt(p_212852_2_.maximum - p_212852_2_.topOffset) + p_212852_2_.bottomOffset);          return new BlockPos(i, k, j);       });    } } in Line int k = random.. there are two errors:    a) when calling the inner random.nextInt(..) with Value ..Maximum = 64 and bottomOffset = 30) the parameter in nextInt will not be 34. In some test i fond ther will be allways an value of 31 by differnet values of Maximum and topOffset it might be the Differenz in Adress range not in Value)      b) when k is the y value for placement. I think there is an random.nextInt(...) to much. the correct line must be: int k = random.nextInt(p_212852_2_.maximum - p_212852_2_.topOffset) + p_212852_2_.bottomOffset;   How To test it:   only set an Breakpoint on line 19 (int k  = ...) in net.minecraft.world.gen.placement.HeightBiasedRange and look wat will be happend.   For Info: I Worrk with Eclipse, Version 2019-19    
    • I can't find any documentation for 1.15.2 forge on how to do this. I basically want a thirst meter that goes above the hunger bar. If anyone knows where any docs for this are or has any source code please let me know! This is my first time using forge, normally I make plugins for Spigot so apologies.
    • Yeah, i tried to fix that exception and didn’t give enough attention to code architecture. I’ll refactor when it will work. It is a totally different than 1.12.2 modding so there is not too much new modes or information about new versions. Thanks.
    • I doubt that it is caused by the government's firewall, as I am currently in China, and I can still build/setup projects without major connection problem (although relatively slow due to the geographical location).
  • Topics

  • Who's Online (See full list)