// 
// Decompiled by Procyon v0.6.0
// 

package com.hypixel.hytale.procedurallib.json;

import javax.annotation.Nullable;
import javax.annotation.Nonnull;
import com.hypixel.hytale.procedurallib.logic.ResultBuffer;

public interface SeedResource
{
    public static final String INFO_SEED_REPORT = "Seed Value: %s for seed %s / %s";
    public static final String INFO_SEED_OVERWRITE_REPORT = "Seed Value: %s for seed %s / %s overwritten by %s";
    
    @Nonnull
    default ResultBuffer.Bounds2d localBounds2d() {
        return ResultBuffer.bounds2d;
    }
    
    @Nonnull
    default ResultBuffer.ResultBuffer2d localBuffer2d() {
        return ResultBuffer.buffer2d;
    }
    
    @Nonnull
    default ResultBuffer.ResultBuffer3d localBuffer3d() {
        return ResultBuffer.buffer3d;
    }
    
    default boolean shouldReportSeeds() {
        return false;
    }
    
    default void reportSeeds(final int seedVal, final String original, final String seed, @Nullable final String overwritten) {
        if (this.shouldReportSeeds()) {
            if (overwritten == null) {
                this.writeSeedReport(String.format("Seed Value: %s for seed %s / %s", seedVal, original, seed));
            }
            else {
                this.writeSeedReport(String.format("Seed Value: %s for seed %s / %s overwritten by %s", seedVal, original, seed, overwritten));
            }
        }
    }
    
    default void writeSeedReport(final String seedReport) {
        System.out.println(seedReport);
    }
}
