    001package net.minecraft.world.gen.layer;
    002
    003public class GenLayerRiverInit extends GenLayer
    004{
    005    public GenLayerRiverInit(long par1, GenLayer par3GenLayer)
    006    {
    007        super(par1);
    008        this.parent = par3GenLayer;
    009    }
    010
    011    /**
    012     * Returns a list of integer values generated by this layer. These may be interpreted as temperatures, rainfall
    013     * amounts, or biomeList[] indices based on the particular GenLayer subclass.
    014     */
    015    public int[] getInts(int par1, int par2, int par3, int par4)
    016    {
    017        int[] aint = this.parent.getInts(par1, par2, par3, par4);
    018        int[] aint1 = IntCache.getIntCache(par3 * par4);
    019
    020        for (int i1 = 0; i1 < par4; ++i1)
    021        {
    022            for (int j1 = 0; j1 < par3; ++j1)
    023            {
    024                this.initChunkSeed((long)(j1 + par1), (long)(i1 + par2));
    025                aint1[j1 + i1 * par3] = aint[j1 + i1 * par3] > 0 ? this.nextInt(2) + 2 : 0;
    026            }
    027        }
    028
    029        return aint1;
    030    }
    031}