public interface IApiHandler
RockBottomAPI.getApiHandler().| Modifier and Type | Method | Description |
|---|---|---|
void |
construct(IWorld world,
double x,
double y,
Inventory inventory,
IRecipe recipe,
int amount,
java.util.List<IUseInfo> inputs,
java.util.function.Function<java.util.List<ItemInstance>,java.util.List<ItemInstance>> outputGetter) |
|
java.util.logging.Logger |
createLogger(java.lang.String name) |
Creates a
Logger with the specified name that will output to the
main logger and also written to the log file. |
int |
getColorByLight(int light,
TileLayer layer) |
Gets a color in the world based on a light value between 0 and
Constants.MAX_LIGHT. |
int[] |
interpolateLight(IWorld world,
int x,
int y) |
Interpolates the light at a position in the world.
|
int[] |
interpolateWorldColor(int[] interpolatedLight,
TileLayer layer) |
Interpolates the four colors of the corners of a position in the world
based on the
TileLayer and the interpolated light from interpolateLight(IWorld, int, int). |
java.util.logging.Logger |
logger() |
|
INoiseGen |
makeSimplexNoise(long seed) |
Returns a new
INoiseGen of the Simplex Noise kind based on the
specified seed. |
void |
readDataSet(com.google.gson.JsonObject main,
AbstractDataSet set) |
|
void |
readDataSet(AbstractDataSet set,
java.io.File file,
boolean asJson) |
|
void |
readDataSet(java.io.DataInput stream,
AbstractDataSet set) |
|
void |
writeDataSet(com.google.gson.JsonObject main,
AbstractDataSet set) |
|
void |
writeDataSet(AbstractDataSet set,
java.io.File file,
boolean asJson) |
|
void |
writeDataSet(java.io.DataOutput stream,
AbstractDataSet set) |
void writeDataSet(AbstractDataSet set, java.io.File file, boolean asJson)
void readDataSet(AbstractDataSet set, java.io.File file, boolean asJson)
void writeDataSet(java.io.DataOutput stream,
AbstractDataSet set)
throws java.lang.Exception
java.lang.Exceptionvoid readDataSet(java.io.DataInput stream,
AbstractDataSet set)
throws java.lang.Exception
java.lang.Exceptionvoid writeDataSet(com.google.gson.JsonObject main,
AbstractDataSet set)
throws java.lang.Exception
java.lang.Exceptionvoid readDataSet(com.google.gson.JsonObject main,
AbstractDataSet set)
throws java.lang.Exception
java.lang.Exceptionint[] interpolateLight(IWorld world, int x, int y)
world - The worldx - The x coordinatey - The y coordinateint[] interpolateWorldColor(int[] interpolatedLight,
TileLayer layer)
TileLayer and the interpolated light from interpolateLight(IWorld, int, int).interpolatedLight - The interpolated lightlayer - The layervoid construct(IWorld world, double x, double y, Inventory inventory, IRecipe recipe, int amount, java.util.List<IUseInfo> inputs, java.util.function.Function<java.util.List<ItemInstance>,java.util.List<ItemInstance>> outputGetter)
int getColorByLight(int light,
TileLayer layer)
Constants.MAX_LIGHT.light - The lightlayer - The layerINoiseGen makeSimplexNoise(long seed)
INoiseGen of the Simplex Noise kind based on the
specified seed.seed - The seedjava.util.logging.Logger createLogger(java.lang.String name)
Logger with the specified name that will output to the
main logger and also written to the log file.name - The name@ApiInternal java.util.logging.Logger logger()