IWorldProvider
Link to iworldprovider
The World Provider interface is used to get even more information out of an IWorld object.
Импорт пакета
Link to импорт-пакета
It might be required for you to import the package if you encounter any issues, so better be safe than sorry and add the import.
import crafttweaker.world.IWorldProvider;
Create a worldProvider
Link to create-a-worldprovider
Normally, you can just get the worldProvider from an IWorld object or some functions, though if yo need to create one yourself, here's how you do it:
Note that this method should only be called inside functions that are meant to be run inside minecraft, not during the loading circle.
ZenScript Copycrafttweaker.world.IWorldProvider.getFromID(int id);
ZenMethods without parameters and ZenGetters
Link to zenmethods-without-parameters-and-zengetters
ZenGetter | ZenMethod | Возвращаемый тип |
---|---|---|
ZenGetter actualHeight | ZenMethod getActualHeight() | Возвращаемый тип int |
ZenGetter actualGroundLevel | ZenMethod getAverageGroundLevel() | Возвращаемый тип int |
ZenGetter cloudHeight | ZenMethod getCloudHeight() | Возвращаемый тип float |
ZenGetter currentMoonPhaseFactor | ZenMethod getCurrentMoonPhaseFactor() | Возвращаемый тип float |
ZenGetter dimensionID | ZenMethod getDimensionID() | Возвращаемый тип int |
ZenGetter height | ZenMethod getHeight() | Возвращаемый тип int |
ZenGetter horizon | ZenMethod getHorizon() | Возвращаемый тип double |
ZenGetter lightBrightnesTable | ZenMethod getLightBrightnesTable() | Возвращаемый тип float[] |
ZenGetter movementFactor | ZenMethod getMovementFactor() | Возвращаемый тип double |
ZenGetter randomizedSpawnPoint | ZenMethod getRandomizedSpawnPoint() | Возвращаемый тип IBlockPos |
ZenGetter saveFolder | ZenMethod getSaveFolder() | Возвращаемый тип string |
ZenGetter seed | ZenMethod getSeed() | Возвращаемый тип long |
ZenGetter spawnCoordinate | ZenMethod getSpawnCoordinate() | Возвращаемый тип IBlockPos |
ZenGetter spawnPoint | ZenMethod getSpawnPoint() | Возвращаемый тип IBlockPos |
ZenGetter voidFogYFactor | ZenMethod getVoidFogYFactor() | Возвращаемый тип double |
ZenGetter worldTime | ZenMethod getWorldTime() | Возвращаемый тип long |
ZenGetter canRespawnHere | ZenMethod canRespawnHere() | Возвращаемый тип bool |
ZenGetter waterVaporize | ZenMethod doesWaterVaporize() | Возвращаемый тип bool |
ZenGetter skylight | ZenMethod hasSkyLight() | Возвращаемый тип bool |
ZenGetter daytime | ZenMethod isDaytime() | Возвращаемый тип bool |
ZenGetter nether | ZenMethod isNether() | Возвращаемый тип bool |
ZenGetter skyColored | ZenMethod isSkyColored() | Возвращаемый тип bool |
ZenGetter surfaceWorld | ZenMethod isSurfaceWorld() | Возвращаемый тип bool |
ZenMethods with parameters
Link to zenmethods-with-parameters
get Biome at a certain Position
Link to get-biome-at-a-certain-position
Use either an IBlockPos object.
Returns an IBiome Object.
ZenScript CopyworldProvObj.getBiome(IBlockPos position);
get MoonPhase for a specific time
Link to get-moonphase-for-a-specific-time
Use a long.
Returns an int.
ZenScript CopyworldProvObj.getMoonPhase(long time);
get Respawn Dimension for a specific player
Link to get-respawn-dimension-for-a-specific-player
Use an IPlayer object.
Returns a new IWorldProvider object.
ZenScript CopyworldProvObj.getRespawnDimension(IPlayer player);
get Brightnes (factor) at a specific
Link to get-brightnes-factor-at-a-specific
Use a float.
Returns a float.
ZenScript CopyworldProvObj.getStarBrightness(float something);
worldProvObj.getSunBrightness(float something);
worldProvObj.getSunBrightnessFactor(float something);
Check if a block has a high humidity
Link to check-if-a-block-has-a-high-humidity
Use an IBlockPos object.
Returns a boolean.
ZenScript CopyworldProvObj.isBlockHighHumidity(IBlockPos pos);