Chunk-Pregenerator

(NOTE THIS MOD REQUIRES MINECRAFT FORGE. Yes i got this problem question frequently enough now)

99.99999999999% of the Mod is documentated on curse. If you have a special info request. Look it up on the Command Information or Command Suggestions which contains actual usefull information.

 

This mod is a Server Utility mod that allows you to pregenerate Worlds.
It can be also used in singleplayer worlds and it can have a great effect on performance!

Anyone who likes this mod, consider supporting me by:

  • Tell the friends/people you know about this
  • Put it in your curse pack (if you have one)
  • Patreon: Link
  • Donating: Link

Either of them would really help me. 

For those who don't know what a Chunks are or what a pregenerator is here you find a explaination:

Chunks are basically a DataStorage for all blocks you see. They are 16x256x16 Blocks areal and the whole world is build out of them.

Every time a chunk loads and it wasn't already created by the world has to be generated.

That means the game has to find out what to place where and ore generation, tree generation has to happen in that chunk.

That is usually very laggy and causes servers to have performance issues or lag issues or stuttering.


A World Pregenerator is a tool that allows you to generate a world in a base radius so that these are already generated and your game has time to prioritize on the important things.
Of course the Pregenartion takes time and is not instantly done. But the time you save is a lot more. Especially on Multiplayer servers.

So that we have this out of the way lets talk about the mod.


This Chunk Pregenerator mod is one of the most efficient ways maybe even the most efficient way to generate chunks.
Yes there are other ways to pregenerate your world but these are either very bad programmed and are slow or have memory leaks in them or don't work because of other mods (the command block option)

Important Info: This mod has a full autocompletion feature for every single command & parameter!
So if you are unsure what to type in press Tab. It will give you options for the most common usecases.


IMPORTANT FOR SERVERS:
Chunk Pregen runs by default on 25% Speed, thats intendet to make a smooth SinglePlayer Experience while still keeping the benefit of the pregenerator (basically play while its running),
This can be disabled by using 2 commands:
/pregen timepertick 250 & /pregen utils setPriority Pregenerator
First one increases the CPU usage drastically (around 12Times) the game will run close to the limit of the Server Watch dog, the second one is basically allocating all the resources to the Pregenerator instead of the game further increasing the speed.


Features:

  • Very userfriendly:
    The Pregenerator has a lot of features to make it more userfriendly
    There a AutoComplete feature that provides a number of options that can be used (if the command needs it),
    the Help Feature that provides information on every single command and on every single parameter if needed.
    If a Suggestion is needed that feature is present for every command that explains you also what each suggestion does.
    Its formatting is also used to highlight split points to make it easier readable.
    On top of that you can customize the Text Output based on what is needed.
    Also for those who like to play while its running there is a UI feature that is toggeable and fully customizeable too.

  • Dynamic CPU Allocation:
    The Pregenerator is designed to be fully dynamic on its usage,
    That means it will not generate 10 chunks and then let the game play,
    it will generate as many chunks as it can fit into a certain customizable time frame (default 40MS) and then give the CPU back to the game.
    This time frame can be set freely and also how much it should be used.

  • Playeable while Pregenerating:
    The Pregenerator is Designed to be used while playing the game,
    While it uses as much CPU as provided it will make sure that the game has priority over the generation.
    That can be controlled too, so that its optional that the pregenerator prioritizes the game.
    This allows to do the Pregeneration to be happening while you actually play.

  • Very Fast Chunk Generation Check:
    The Pregenerator uses a couple tricks to find out if a Chunk was already generated.
    There is the normal check (PostProcessingOnly) that is not really fast but has a 100% accuracy even on already generated chunks,
    and there is the fast check which is as fast as the HHD/SSD can handle it, but that one looses accuracy because it checks not so deepply.
    This faster check allows to check this fast that it can check 40k chunks within seconds.
    While the higher accuracy one checks only around 20-50 in a second, but for just generation a basic check that is faster is enough the higher accuracy is for its own set of things.

  • Faster Chunk Generation:
    The Chunk Pregenerator has a faster generation logic then other Pregenerators,
    that is not achieved by hacking into the game and changing things.
    There are certain checks that reduce generation speed down by a lot, these are not required and can be not used without any harm,
    that allows the pregenerator to run at least 20-50% faster then other ones.

  • Very Efficient Memory Managment:
    The Chunk Pregenerator has a Special Memory handler that keeps track of its own memory usage,
    and makes sure that everything that it creates get cleaned up.
    That has ofcourse its limits and it can't cleanup everything if someone makes a mistake.
    But compared to the other options its targeted at bigger scale generations.

  • Type Based Generation Options:
    The Chunk Pregenerator has not only normal Generation options,
    it also has a terrain only generation which allows to create a Fog of war effect.
    This effect on the other hand doesn't remove the full Generation lag since only the terrain is created and Chunks still cause lag when a player comes nearby,
    But while the terrain only option is not lagfree it allows to have a worldview without the features inside of a world and provide for multiplayer a fair option for everyone.

  • Retrogen:
    The Chunk Ppregenerator has a Retrogen Feature that allows you to regenerate certain mod elements in the area of the World that you want to regenerate in.
    Without the need of actual players loading chunks for you.
    Selection of which generators should be used can be done via gui with easy to see which ones are selected and which ones are not. Same goes for the command. Autocomplete feature supports that too.
    Duplicated retorgens get skipped and only the last retrogeneration is keept track of  so you can run them multiple times if wanted.
  • Dimension Loading:
    The Chunk Pregenerator will automatically load Dimensions that it is requested to Pregenerate in.
    It will also keep that dimension loaded without any extra lag or causing any sort of prevention of unloading dimensions.
    But it will prevent the unload feature of its own command so that you can not unload the dimension it is working in.

  • A Task List:
    The Chunk Pregenerator has a Tasklist where it stores the Current & Other tasks in that need to be executed.
    That means you can add a bunch of work tasks at once and it will go through every single one of them.
    On top of that this List can be viewed and changed at any given time of the Pregeneration.
    You can remove every single Index individually and they don't have to be in the first or last point.
    On top of that if the Pregenerator Crashes it will remember that it crashed and continues the task after a certain waiting time.

  • ModPack Support:
    The Pregenerator has a Command Called. LoadFromFile that loads tasks from a txt file.
    This feature has been expanded on. It automatically checks on a World Creation if a "onWorldCreation.txt" exists,
    If that is the case it will automatically run it with its instructions, allowing modpackdevs to pregenerate automatically for their users to provide a better experience.
    On top of that if the config Folder is the first time generated it will also generate a example file.

  • World Control:
    The Pregenerator has a couple World Controlling features to use.
    It Allows to Delete Unlaoded Chunks while being in the game.
    Make Savezones for Structures where they can not be generate
    Remove Already Generated Structures from the World,
    Or Just cleanup Entities/TileEntities on a World or per Chunk Basis.
    These features can be either accessed from the GUI (by pressing I while in the game) or via commands.
    (The TileEntity/Entity Cleanup is only accessable via GUI and the other only via commands).
    These are just some features to help people to remove things they don't want or just cleanup their world.

  • Intigrated Profiler:
    The Chunk Pregenerator has a Intigrated Profiler.
    Now this Profiler is very basic and can not replace other Profiler mods,
    but it is full UI Based Allowing to find issues inside of the World.
    It lists the Lag of the Server / Each Dimension without causing any lag,
    It also lists the Server Ram at the given moment, how many packets that are being processed by the Server.
    On top of that it has a detailed info for 1 Dimension (Selectable) that show things that some other profilers don't provide.
    It lists how many BlockTicks Listed up, How many TileEntities/Tickable/TileEntities/Entities there are, how many BlockChanges happen in the World,
    It also provides a lastTick & Average Values of most of these things.
    These functions cause very little lag by itself but it can be turned on or off whenever its needed.
    On top of that these things can be seen by any user that has the mod installed on the client and it will cause no extra lag to the server by viewing it.

Downsides:

  • Restart Suggested:
    The Pregenerator has a lot of things implemented to make a clean and none memory leaking progression but after a huge generation or a lot of tiny generations its still suggested to restart the game to make sure that everything is cleaned up. To Prevent issues.
  • Memory Usage:
    The Pregenerator generates Every Single Position where it should and can generate Chunks, for larger generations that takes up a huge chunk of memory. Make sure when you generating chunks that you leave 1-2GB free if you see that you get close to max memory usage split up the tasks.

How to Retrogen:

If you want to retrogen you have to options for selecting:
Via GUI:
You can access the Gui will can be accessed by the world view which can be accessed by pressing the "I" key.

You enable all the handlers you want to retrogenerate and then go to the retrogen step.

Via Commands:
You use the /pregen gen selectRetrogenerator command to select the retrogenerator.
For adding you would use /pregen gen selectRetrogenerator add com.rwtema.densores.WorldGenOres
Or for removing you would use: /pregen gen selectRetrogenerator remove com.rwtema.densores.WorldGenOres
These can be also auto selected by hitting tab. This mod supports that fully.

So how do you run a retrogeneration. Very simple. You create a normal pregen task like you would for a pregeneration.
with /pregen gen startradius square 0 0 100 0 Retrogen
The "Retrogen" at the end will tell the pregenerator to run a Retrogeneration instead of a Pregeneration.
Thats about it.

Command Information:

  • /pregen gen startradius
    Description: Generates a Square or Circle Radius
    Parameters:
    Generation Type: Which shape the Generation should have
    X Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Z Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Radius: How big the Radius in Chunks should be. (if 'b' infront of the number or after ~ means block distance)
    (Optional) Dimension: The Dimension the Generation should be in (Auto Loads Dimensions)
    (Optional) Processing Rule: Which type of Generation it should use.

  • /pregen gen startexpansion
    Description: Generates a area around a already generated area
    Parameters:
    Type: Which Shape the generation should have
    X Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Z Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Min Radius: The Radius the Generation should start at. (if 'b' infront of the number or after ~ means block radius
    Max Radius: The Radius the Generation should end at. (if 'b' infront of the number or after ~ means block radius
    (Optional) Dimension: The Dimension the Generation should happen in. (It Autoloads dimension if they are unloaded)
    (Optional) Processing Rule: Which type of Generation it should use.

      

  • /pregen gen startmassradius
    Description: Generates a Massive Amount of Area
    Parameters:
    Generation Type: Which shape the Generation should have
    X Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Z Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Radius: How big the Radius in Chunks should be. (if 'b' infront of the number or after ~ means block distance)
    (Optional) SplitRadius: In How much radius the Calculator should split the tasks. Default: 1000 Chunks, Max: 1000 Chunks, Min: 100 Chunks
    (Optional) Dimension: The Dimension the Generation should be in (Auto Loads Dimensions)
    (Optional) Processing Rule: Which type of Generation it should use.

  • /pregen gen startarea
    Description: Generates a Plane of Chunks
    Parameters:
    Type: Which Shape the generation should have
    StartX: The Chunk X Position where the generator should start at. (if 'b' infront of the number or after ~ means block position)
    StartZ: The Chunk Z Position where the generator should start at. (if 'b' infront of the number or after ~ means block position)
    EndX: The Chunk X Position where the generator should end at. (if 'b' infront of the number or after ~ means block radius
    EndZ: The Chunk Z Position where the generator should end at. (if 'b' infront of the number or after ~ means block radius
    (Optional) Dimension: The Dimension the Generation should happen in. (It Autoloads dimension if they are unloaded)
    (Optional) Processing Rule: Which type of Generation it should use.

  • /pregen gen startregion
    Description: Generates a full RegionFile
    Parameters:
    Region File X: The X Position in Chunks of the Region File (if 'b' infront of the number or after ~ means block position)
    Region File Z: The Z Position in Chunks of the Region File (if 'b' infront of the number or after ~ means block position)
    (Optional) Dimension: The Dimension the Generation should happen in. (It Autoloads dimension if they are unloaded)
    (Optional) Processing Rule: Which type of Generation it should use.

     

     

  • /pregen gen startWorldBorder
    Description: Generates everything inside of a worldBorder
    Parameters:
    (Optional)Dimension: The Dimension it should generate in
    (Optional) SplitRadius: In How much radius the Calculator should split the tasks. Default: 1000 Chunks, Max: 1000 Chunks, Min: 100 Chunks
    (Optional) Processing Rule: Which type of Generation it should use.

     

     

  • /pregen gen loadFromFile
    Description: Loads tasks from a File
    Parameters:
    FileName: The Name of the file that should be loaded in the config folder from + extension. Example.txt

     

  • /pregen gen selectRetrogenerator
    Description: Adds/Removes the Retrogenerators for the RetroPregenerator
    Parameters:

    Add/Remove: If the Retrogenerator should be added or removed.
    Retrogenerator: The ID of the Retrogenerator that should be added or removed

     

  • /pregen delete deleteChunk
    Description: Deletes a Single Unloaded Chunk
    Parameters:
    X Position: The X Chunk Position of the Deletion. (if 'b' infront of the number or after ~ means block position)
    Z Position: The Z Chunk Position of the Deletion. (if 'b' infront of the number or after ~ means block position)
    (Optional) Dimension: The Dimension the Deletion should be happening in
    (Optional) Delay: How long the Deleter should wait until it should start (in ticks)

     

     

  • /pregen delete deleteRadius
    Description: Deletes a Radius of Unloaded Chunks
    Parameters:
    Deletion Type: Which shape the Generation should have
    X Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Z Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Radius: How big the Radius in Chunks should be. (if 'b' infront of the number or after ~ means block distance)
    (Optional) Dimension: The Dimension the Deletion should be happening in
    (Optional) Delay: How long the Deleter should wait until it should start (in ticks)

     

     

  • /pregen delete deleteExpansion
    Description: Deletes a Area of Unloaded Chunks around an Existing Area
    Parameters:
    Deletion Type: Which shape the Generation should have
    X Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Z Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Min Radius: The Radius the Deletion should start at. (if 'b' infront of the number or after ~ means block distance)
    Max Radius: The Radius the Deletion should end at. (if 'b' infront of the number or after ~ means block distance)
    (Optional) Dimension: The Dimension the Deletion should be happening in
    (Optional) Delay: How long the Deleter should wait until it should start (in ticks)

     

     

  • /pregen delete deleteRegion
    Description: Deletes a full 1024 Chunk Set out of the World Directory
    Parameters:
    X Position: The ChunkX Position of the File that should be deleted. (if 'b' infront of the number or after ~ means block position)
    Z Position: The ChunkZ Position of the File that should be deleted. (if 'b' infront of the number or after ~ means block position)
    (Optional) Dimension: The Dimension the Deletion should be happening in

     

     

  • /pregen delete deleteDimension
    Description: Deletes an Entire Unloaded Dimension
    Parameters:
    Dimension: The Dimension that should be deleted

     

     

  • /pregen delete deleteMassRadius
    Description: Deletes a Massive Area
    Parameters:
    Deletion Type: Which shape the Generation should have
    X Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Z Center: Which Chunk the center should be in. (if 'b' infront of the number or after ~ means block position)
    Radius: How big the Radius in Chunks should be. (if 'b' infront of the number or after ~ means block distance)
    (Optional) Dimension: The Dimension the Deletion should be happening in
    (Optional) Delay: How long the Deleter should wait until it should start (in ticks)

     

     

  • /pregen info listen
    Description: Adds the Sender to Pregenerator/Deleter info

     

     

  • /pregen info unlisten
    Description: Removes the Sender from Pregenerator/Deleter info

     

     

  • /pregen info EditInfo
    Description: Changes the Information you get from the Processor Logger
    Parameters:
    Add/Remove: If you want to Add/Remove the Index out of the Logger List
    Type: The Info you want to Add/Remove

     

     

  • /pregen info setAutoListenState
    Description: Reads or Sets the AutoListen state that is requested
    Parameters:
    (Optional) State: The state the sender is setting it to

     

     

  • /pregen info ShowTaskList
    Description: Shows all the Tasks of the Pregenerator

     

     

  • /pregen info ShowRunningTime
    Description: Shows how long the Pregenerator is Running

     

     

  • /pregen info ShowChunkFile
    Description: Shows a Detailed info about the ChunkSaveFile
    Parameters:
    Chunk X: The X Position of the Chunk that the file you want to check with. (if 'b' infront of the number or after ~ means block position)
    Chunk Z: The Z Position of the Chunk that the file you want to check with. (if 'b' infront of the number or after ~ means block position)
    (Optional) Dimension: The Dimension the Generation should be in (Auto Loads Dimensions)

     

     

  • /pregen structure createSaveZone
    Description: Creates a plane that prevents selected structures not to generate
    Parameters:
    Dimension: The Dimension the Savezone should be in
    Type: Which Structures the SaveZone should effect
    X Center: The Center X (in Chunks) of the SaveZone. (if 'b' infront of the number or after ~ means block position)
    Z Center: The Center Z (in Chunks) of the SaveZone. (if 'b' infront of the number or after ~ means block position)
    Radius: The Radius in Chunks of the SaveZone (if 'b' infront of the number means BlockDistance)

     

     

  • /pregen structure ClearSaveZone
    Description: Clears a Created SaveZone
    Parameters:
    Dimension: Which Dimension the SaveZone is at
    Type: Which Structure SaveZone should be effected
    (Optional) Index: Which index should be deleted

     

     

  • /pregen structure ListSaveZones
    Description: Lists all the SaveZones that exist
    Parameters:
    Dimension: The Dimension that needs to be checkt
    Type: The Structure that should be checkt for

     

     

  • /pregen structure listStructures
    Description: Lists the Structures that are planned or already generated
    Parameters:
    Dimension: The Dimension the Structure should be found at. (if unlisted
    Type: The Structure that should be listed
    (Optional) ShowType: If it should list failed structures or only Failed Structures

     

     

  • /pregen structure deleteStructure
    Description: Deletes a Structure and optionally regenerates the Chunks for Complete removal
    Parameters:
    Dimension: The Dimension the Structure is in (if not listed its not deleteable)
    Type: The Structure that should be deleted (if not listed its not deleteable)
    X Block Position: The Ruff X Block Position of the Structure
    Z Block Position: The Ruff Z Block Position of the Structure
    (Optional) Delete: If the Structure Should be removed from the World

     

     

  • /pregen structure resetAllStructures
    Description: Deletes all the Generated structures
    Parameters:
    (Optional) Dimension: Which dimension the Structures should be resetted in

     

     

  • /pregen utils setPriority
    Description: Changes if the Pregenerator is taking over CPU priority or not
    Parameters:
    (Optional) Type: If the Game or Pregenerator should be prioritized

     

     

  • /pregen utils unloadDimension
    Description: Unloads a Dimension
    Parameters:
    Dimension: The Dimension that should be unloaded

     

     

  • /pregen utils unloadDimensionRange
    Description: Unloads a Range of Loaded-Dimensions
    Parameters:
    Min Range: The Lowest Value of Dimension that should be unloaded
    Max Range: The Highest Value of Dimension that should be unloaded

     

     

  • /pregen utils setPlayerLimit
    Description: Pauses the Pregenerator when PlayerLimit is reached
    Parameters:
    Amount: How many players should be online to Pause the Pregenerator

     

     

  • /pregen utils removeDelay
    Description: Removes the Current delay of the Pregenerator/Deleter

     

     

  • /pregen utils findSpawn
    Description: Finds the Spawn in the Selected Dimension
    Parameters:
    (Optional) Dimension: The Dimension that the Spawnpoint is needed for

     

     

  • /pregen utils SkipChunks
    Description: Skips Chunks in a Running Pregeneration
    Parameters:
    Amount: How many chunks that should be skipped

     

     

  • /pregen utils SetSkipMarker
    Description: Sets a Marker for Skipping already Generated Chunks

     

     

  • /pregen utils LoadSkipMarker
    Description: Loads the SkipMarker and Applies it to the current Task. Skip Marker gets resets

     

     

  • /pregen utils enableTracking
    Description: Enables the Pregenerators Profiler that shows a bit of more detailed info. (Requires a client to have the mod installed)

     

     

  • /pregen utils disableTracking
    Description: Disables the ServerTracker

     

     

  • /pregen utils gc
    Description: Calls Java GC to clear up Memory

     

     

  • /pregen help
    Description: Explains all the Commands and each command Parameter to the User
    Parameters:
    (Optional) Command: The Sub Command you would like to get Explained or the SubCategory that you would like to know explained

     

     

  • /pregen suggestion
    Description: Prints out Suggestions for the Selected command
    Parameters:
    Command: The Command you want suggestions for

     

     

  • /pregen continue
    Description: Starts the Pregenerator with a task out of the TaskList

     

     

  • /pregen stop
    Description: Stops the current task and optionally deletes also the task
    Parameters:
    (Optional) Deletion: If it should clear the entire tasklist or just the current task

     

     

  • /pregen timepertick
    Description: Sets the amount of Time per each Tick has
    Parameters:
    (Optional) Time: The Time each per tick should have (in ms)

     

     

  • /pregen clear
    Description: Deletes the TaskList
    Parameters:
    (Optional) Index: Which index of the TaskList should be cleared

 

Command Suggestions:

  • startradius
    /pregen gen startradius square 0 0 100
         - Generates everything within 100 Chunks radius in the Senders Dimension (Server = Overworld, Player = The Dimension the Player is in)
    /pregen gen startradius square 0 0 50 -1 TerrainOnly
        - Generates only Terrain within 50 Chunks radius, in the Nether
    /pregen gen startradius square 0 0 b1000
        - Generates everything within 1000 Blocks radius in the Senders Dimension (Server = Overworld, Player = The Dimension the Player is in)
    /pregen gen startradius square 0 0 100 0 PostProcessingOnly
        - Populates everything within 100 Chunks radius without generating new Chunks in the Overworld
    /pregen gen startradius square ~ ~ 100
        - Generates a 100 Chunk Radius around the Players Position
    /pregen gen startradius square ~-100 ~ 100
        - Generates a 100 Chunk Radius -100 Chunks X Away from the player
    /pregen gen startradius square s s 100
        - Generates a 100 Chunk Radius around the Spawn
    /pregen gen startradius cicle 0 0 100
        - Generates a Circle of a 100 Chunk Radius
    /pregen gen startradius square 0 0 100 0 Retrogen
        - Retrogenerates all the Selected RetroGenerators in the overworld of a 100 chunk Radius

     

     

  • startexpansion
    /pregen gen startexpansion square 0 0 100 200
        - Generates everything within a area from 100 Chunks to 200 Chunks in every direction
    /pregen gen startexpansion square 0 0 100 200 0 TerrainOnly
        - Generates only Terrain within a area from 100 Chunks to 200 Chunks in every direction in the Overworld

     

     

  • startmassradius
    /pregen gen startmassradius square 0 0 10000
        - Generates a 10000 Chunk Radius with multible tasks of 1000 Chunk Radius in the dimension the Sender is in
    /pregen gen startmassradius square 0 0 10000 100
        - Generates a 10000 Chunk Radius with multible tasks of 100 Chunk Radius

     

     

  • startarea
    /pregen gen startarea -b1000 -b1000 b1000 b1000
        - Generates 1000 Block radius from the Center of the world
    /pregen gen startarea ~-100 ~-100 ~100 ~100 -1 TerrainOnly
        - Generates a 100 Chunk Radius with only Terrain around the Players Position in the Nether

     

     

  • startregion
    /pregen gen startregion 20 20
        - Generates everything at the Region File 0 0 at the dimension the sender is in

     

     

  • startWorldBorder
    /pregen gen startWorldBorder
        - Generates everything inside the Worldborder in the dimension the player is in
    /pregen gen startWorldBorder -1
        - Generates everything inside the Worldborder in the Nether

     

     

  • loadFromFile
    /pregen gen loadFromFile Example.txt
        - Loads the none existed Example file and reads the tasks

     

     

  • deleteChunk
    /pregen delete deleteChunk 100 200
        - Deletes a Unloaded Chunk at X100 Z200 at the Dimension that the sender is at

     

     

  • deleteRadius
    /pregen delete deleteRadius square 0 0 100 -1 200
        - Deletes a 100 Chunk Area around the World Center in the nether and it waits 10 seconds before starting

     

     

  • deleteExpansion
    /pregen delete deleteExpansion square 0 0 100 200 -1
        - Deletes a area from 100 Chunks to 200 Chunks in the Nether

     

    deleteRegion
    /pregen delete deleteRegion 100 200
        - Deletes the Region File that is at Chunk Position X100, Z200

     

    deleteDimension
    /pregen delete deleteDimension 1
        - Deletes the End
    /pregen delete deleteDimension -1
        - Deletes the Nether

     

    deleteMassRadius
    /pregen delete deleteMassRadius square 0 0 100 -1 200
        - Deletes a 100 Chunk Area around the World Center in the nether and it waits 10 seconds before starting

     

    listen
    /pregen info listen
    - Adds the Player to the Running Pregenerator/Deleter Logger

     

    unlisten
    /pregen info unlisten
        - Removes the Player from the Running Pregenerator/Deleter Logger

     

    EditInfo
    /pregen info EditInfo add CPU-Usage
        - Add the CPU Usage information

     

    setAutoListenState
    /pregen info setAutoListenState
        - Prints out the senders Auto List
    /pregen info setAutoListenState reset
        - Resets the Listener State of the Sender
    /pregen info setAutoListenState ignoring
        - Sets the Sender to ignore any starting Processess infos. Even the senders ones
    /pregen info setAutoListenState listening
        - Sets the Sender to Automaticallly Listening to any Process info that apears

     

    ShowTaskList
    /pregen info ShowTaskList
        - Shows all the Tasks that are stored

     

    ShowRunningTime
    /pregen info ShowRunningTime
        - Shows how long the Pregenerator is running

     

    ShowChunkFile
    /pregen info ShowChunkFile 0 0 1
        - Shows the Region File 0.0.mca in the End

     

    createSaveZone
    /pregen structure createSaveZone 0 Village 0 0 100
        - Creates a SaveZone where villages can't spawn within 100 Chunks of the Center of the world

     

    ClearSaveZone
    /pregen structure ClearSaveZone 0 Village last
        - Deletes the last SaveZone for Villages in the Overworld
    /pregen structure ClearSaveZone 0 Village first
        - Deletes the first SaveZone for Villages in the Overworld
    /pregen structure ClearSaveZone 0 Village 5
        - Deletes the 5th SaveZone for Villages in the Overworld

     

    ListSaveZones
    /pregen structure ListSaveZones 0 Village
        - Lists all the Villages in the Overworld
    /pregen structure ListSaveZones -1 Fortress
        - Lists all the Fortresses in the Nether

     

    listStructures
    /pregen structure listStructures 0 Village
        - Shows all Villages on the Overworld
    /pregen structure listStructures -1 Fortress OnlyNoneGenerating
        - Shows only all to Small Fortresses that wouldn't generate

     

    deleteStructure
    /pregen structure deleteStructure 0 Village 0 0
        - Deletes the closest Village to 0 0 from the Files but leaves it in the World
    /pregen structure deleteStructure 0 Village 0 0 delete
        - Deletes the closest Village to 0 0 and removes it from the World

     

    setPriority
    /pregen utils setPriority
        - Prints out the Current Priority
    /pregen utils setPriority game
        - Set the CPU Priority to the Game
    /pregen utils setPriority pregenerator
        - Set the CPU Priority to the Pregenerator

     

    unloadDimension
    /pregen utils unloadDimension -1
        - Unloads the Nether
    /pregen utils unloadDimension 1
        - Unloads the End

     

    unloadDimensionRange
    /pregen utils unloadDimensionRange -1 1
        - Unloads the End & The Nether
    /pregen utils unloadDimensionRange -1100 -1000
        - Unloads all the GalacticCraft Dimensions

     

    setPlayerLimit
    /pregen utils setPlayerLimit disable
        - Resets the PlayerLimit to ignoring
    /pregen utils setPlayerLimit 10
        - Pauses the Pregenerator when 10 Players are online

     

    removeDelay
    /pregen utils removeDelay
        - Removes the Delay of a Running Pregenerator/Deleter

     

    findSpawn
    /pregen utils findSpawn
        - Finds the SpawnPoint of the CommandSenders Dimension
    /pregen utils findSpawn -1
        - Finds the SpawnPoint of the Nether

     

    SkipChunks
    /pregen utils SkipChunks 1000
        - Skips 1000 Chunks of the Current Progress

     

    SetSkipMarker
    /pregen utils SetSkipMarker
        - Sets a Marker that allows you to skip a certain amount of progress

     

    LoadSkipMarker
    /pregen utils LoadSkipMarker
        - Loads a Skip Marker and Applies it to the Current Pregeneration

     

    enableTracking
    /pregen utils enableTracking
        - Enables the ServerProfiler that can be seen via the UI

     

    disableTracking
    /pregen utils disableTracking
        - Disables the ServerProfiler

     

    help
    /pregen help startradius
        - Explains the Basic Pregen Command for you

     

    suggestion
    /pregen suggestion startradius
        - Provides suggestions on the startradius command

     

    continue
    /pregen continue
        - Continues the First Task in the TaskList

     

    stop
    /pregen stop
        - Stops the Running Processor
    /pregen stop delete
        - Stops the Processor and Deletes the Running Pregen Task if there was one
    /pregen stop deleteAll
        - Stops the Processor and Deletes the Pregen TaskList

     

    timepertick
    /pregen timepertick
        - reads the current TimePerTick
    /pregen timepertick default
        - Resets the timepertick to teh default value (40)
    /pregen timepertick 250
        - Sets the time per tick to the most optimal speed that you can gain. At least on the Devs testing it apeared to be

     

    clear
    /pregen clear
        - Clears all the Tasks in the Task Storage and stops the Pregenerator
    /pregen clear first
        - Clears the First index of the TaskStorage and replaces the current PregenTask
    /pregen clear last
        - Clears the last index of the TaskStorage
    /pregen clear 5
        - Clears the 5th index out of the TaskStorage

     

IngameGUI Documentation:

The Ingame UI or GUI is a feature to allow users to move away from text messages and allow a more focused information flow and easier to understand information overall.
This UI is disabled by default for the tracking and enabled by default for Pregeneration.
But to see that UI/GUI the mod is required on the ClientSide but its not required to play on a server just to draw things.

To Access the GUI when the mod is installed on the Client. Just press the "I" key (can be changed) and this Gui Will show up.

This UI is the Options menu that allows to enable/disable features or edit the contents of the features.

  • Disable/Enable PregenUI: Toggles if Pregenerator UI can be seen while the Chunk Pregenerator is running.
  • PregenUI Options: Allows to change settings on what information is shown on the Pregenerator UI and where it is placed and which size it is.
  • Enable/Disable TrackerUI: Toggles the Profiling UI to display the Player the Profiling information that is being done. (Seeing the Profiling information doesn't require admin rights but to enable the UI you need admin rights)
  • TrackerUI Options: Allows to Change settings on what information is displayed on the Profiling UI and where its placed and how big it is.
  • World View: Allows to see detailed information about the World, that information can be on a per chunk or per world basis. To access this tab you require admin rights else the button will be disabled. (On servers the client sends a request packet to validate before enabling the button)
  • Back: Goes back into the game screen.

While any of these Guis are open the game does not pause keep that in mind!

When Selecting the UI Options button this Gui will apear:

The first list of things are settings that effect the UI directly and not the contents itself.

  • Update Rate: The Frequency of how many packets per second with a information request is being sended. Default: 20x a second. Minimum: 1x a second Maximum: 20x a second.
    The Request Frequency has no effect on server performance just on client networkusage.
  • UI YPosition: Where the UI should sit in the screen on the Y Axis. The 3 Options are: Bottom, Top, Center. Default: Bottom.
  • UI XPosition: Where the UI should sit in the screen on the X Axis, The 3 Options are: Left, Right, Center. Default: Right
  • Scale: This defines if the Gui Should be big or small. Defaults: Small

The second part decides on what information is being displayed.

  • Enable/Disable TaskType: Which type of Generation it is: A AreaGeneration, a Radius Generation, a Circle Generation etc.
  • Enable/Disable Radius Info: Shows how large this pregeneration at the moment is.
  • Enable/Disable TaskCenter: Shows where the center of the Pregeneration is (in chunks)
  • Enable/Disable Processing Type: Which type of Generation it is: Terrain Only, PostProcessing (with Terrain or without) or if it blocks PostProcessing.
  • Enable/Disable Delay Info: Shows if the current task is prevented to run for a certain amount of time. (is only visible if a delay is present)
  • Enable/Disable Chunk Info: Shows how many Chunks in the Dimension that the Pregenerator is running in are loaded at any given time. (To Prevent show if there a problem somehow so crashes can be prevented)
  • Enable/Disable Running Time: Displays how long the Pregenerator has been running or not running since the start of the task. (Displayed in Days:Hours:Minutes:Seconds)
  • Enable/Disable Lag-Meter: Shows how many Milliseconds per game tick are being used and how much is aviable. (If there is a (Paused) that means the tool isnt running because the game lags to much)
  • Enable/Disable Ram Info: Shows the Current Usage of Ram and how much is maximum aviable.
  • Enable/Disable Loaded Files Info: This info shows how the Current loaded save Files on the Server while running. This number should stay at 20 Files if it goes above 60 for longer then a couple seconds (max 1 minute) then you have a memory leak and the Pregenerator fails to do its job.
  • Enable/Disable PlayerLimitInfo: Shows how many Players are online and how many players are required to be online to pause the pregenerator. (Only shows if the info requirement is enabled)
  • Enable/Disable Process: Shows how many Chunks are already being generated out of how many should be generate.

All these things can be enabled disabled at any given time without any sort of issues.


Next is the Tracking UI Options which is close to the UI Options but has different settings.

 So lets start with the top 6 options.

  • Update Rate: The Frequency of how many packets per second with a information request is being sended. Default: 20x a second. Minimum: 1x a second Maximum: 20x a second.
  • UI YPosition: Where the UI should sit in the screen on the Y Axis. The 3 Options are: Bottom, Top, Center. Default: Bottom.
  • UI XPosition: Where the UI should sit in the screen on the X Axis, The 3 Options are: Left, Right, Center. Default: Left
  • Scale: This defines if the Gui Should be big or small. Defaults: Small
  • Show Detail: If the Tracker should show a detailed information about the Profiler or if it should be very basic information (Lag, Ram & each worldlag)
  • Detailed Dimension: Which dimension the detailed information should target at.

Now lets get the the Informations that can be enabled/disabled.
But here is a tiny difference between the options & tracking options.
There are None Detailed Infos and Detailed infos that either show or not show if detailed info is enabled/disabled.

Side note: If something means average that means it uses the values over 40 ingame ticks and combines those values and devides it by 40 to get an average.
Lets start with the none detailed ones:

  • Enable/Disable ServerRam: Shows the Ram information about the server. How much is provided and how much is being used.
  • Enable/Disable PacketData: Shows how many packets the server received and processed. (Note not every single packet that the server receives get processed by the server itself that only happens if it is needed that the packet gets processed in snyc with the world)
  • Enable/Disable Server Usage: Shows the Average ms that the server uses and also the TPS of the server at that point.
  • Enable/Disable Worlds-Usage: Displays the Average ms that each world uses. This can be a big one so be warned.

Now we get to the Detailed infos.

  • Enable/Disable Dim-Usage: Displays the Average & lastTick usage of the selected world.
  • Enable/Disable LoadedChunks: Displays  the LoadedChunk count of the selected world.
  • Enable/Disable BlockChanges: Diplays how many setBlockCalls with blockUpdates are being done on average and last tick. (This can be a lag source since crops & farms do these a lot)
  • Enable/Disable BlockTicks: Displays how many Requested BlockDelay Ticks are in the list of to process. (For example what a repeater uses to delay itself), MC in 1.8.9 or older can only process 1000 Of these per game tick while 1.10.2 or newer process 65k per tick if this number keeps growing without stopping that means there is a issue. What to also keep in mind is that the ticks are not executed instantly so there can be a bunch of them ready but being processed like 1 minute later.
  • Enable/Disable TileEntities: This Displays the LoadedTileEntity Count & Ticking TileEntity count in the dimension.
  • Enable/Disable Entities: This Displays the Loaded Entities count in the Dimension.

 Next the Chunk View button is on the list, when this button is pressed then this gui shows up:

So there is 4 Options to select from:

  • Chunks: Which allows you to see detailed info about every single Chunk and its contents,
  • TileEntities: Which lists every single TileEntity type and how many of them are there,
  • Entities: Which lists every single Entity Type and how many of them are there
  • Structures: Which lists you every single Structure and where they are and how many components they have.
  • Retrogen: Shows you the Options of what the RetroGenerator of Chunk Pregen can do and can not do.
  • Back: Which opens up the previouse Gui Screen.

Lets do Chunk View since that is the most complex one and we get a lot of the stuff out of the way after we are done:

This Gui Lists you a lot of things and also uses a lot of resources of your server.
First of all When the gui is the first time opened its is blank and also displays that the reload button needs to be pressed.
The Reason: To collect this data the server has  to process every single chunk of and sort everything together (in sync with the game) and then split the data so that no Packet gets overfilled with data and cause a crash. And when you have 10000 chunks loaded  that can cause a lot of packets to be send. So this has to be updated manually. This also has the side effect that there is a snapshot of all the chunks how they were and all of the things.
But now lets get started on the Buttons:

  • Dimension Button: Allows to select which dimension the server should collect the data for (wipes the current data on the client and requires a reload click when used). When clicked without shift it goes up in the list while pressed with shift it goes backwards through the list.
  • ReloadDims Button: To Prevent network lag the Aviable dimensions are being collected once on the open of the Gui, but dimensions can load/unload dynamicly pressing this button updates the list of aviable dimensions for the user to  choose from.
  • Reload Button: Tells the Server to collect the data for that client, note Lagspikes can happen through this button since it will process every single chunk (even so it is optimized).
  • Sorter Button: Allows to Sort the Chunks by certain elements: (Distance, TileEntityCount, TickingTileEntityCount, EntityCount, RandomBlockTicks Blocks) Pressing it without shift causes it to sort, Pressing it with Shift cycles through the options.
  • Back Button: Goes back to the Previouse Gui.
  • +- Buttons: Allows to go back and forth through the list of objects. (Note Scrollweel also works to do it faster)
  • 0/697 Text: Shows you where you are in the list and how many Chunks are provided at this given time.
  • Entities Button: Displays all the Different Entity Types and their count for that chunk.
  • TileEntities Button: Displays all the Different TileEntity Types and their count for that chunk.
  • Teleport Button: Teleports the Player directly to that Chunk.

Now lets go into the Pink area which displays all the information about each chunk.

First Chunk X & Z and Distance are there for the Position of the Chunk in Chunk Position and how far away the Player is from that Chunk. When pressing Shift that info is converted to block distances.

LoadedEntities & TileEntities & Ticking TileEntities shows the information how many of these are actually present inside of that Chunk and for further detail the Tile/Entities Button can be pressed.

The Random Tick Blocks are a display how many blocks actually want random ticks in that chunk allowing to track down chunks that have especially high one of these. (Crops/Leaves/Grass and other things use that methode)


Now lets go into the Tile/Entity view and look what is there. This shows off only the TileEntity view since both are equal in design and functionality. It dislays just entities instead of TileEntities.

This Gui provides you information for each Tile/Entity type (their registry name) and how many are there in their chunk.
To keep it quick +- Button or scroll weel allow you to move around on the list.
The 0 / 2 is where you are at.
And the Delete button removes the Tile/Entities of that type in the Chunk and Prints out how many it had Deleted. With Entities that can be tricky since these can move out of the Chunk While you gain the data so they are in but on the deletion pressing its not in there anymore.
For TileEntities that is not a problem. But when you delete Chests or Furnaces they Drop their Items on to the Ground. Keep that in mind. Also the Block gets replaced with air too so it removes the TileEntity and the Block!.

Now lets get to the Last GUI and thats the Entity/TileEntity View. These are again combined in the documentation because they are equal but infos just are different.

This Gui works basically like the Chunk Gui and Entities/TileEntities Gui

You have a Reload/Dimension/DimensionReload button that handles like in the Chunks Gui.
But it displays Entities/TileEntities for the Entire Dimension instead of a Per Chunk Basis.
The +- buttons or Scrollwheel to go up and down on the list. The 0 / 2 to show off at which point in the list you are and then the Type and count for which entity/tileentity is being represented.
There is also a newly added sort button sort button that allows to sort between the name and the count of Entities/TileEntities.
And a Delete Button for removing entirely out of the world.
And the Back Button that to go back to the Previouse Screen.

Structure View:


This Gui is designed after the Chunk Gui and also very Straight Forward:
Reload & Reload Dimension are the reset button.
Dimension selects which dimension you want to search for structures in.
The Type Button is the Structure Sort button which basically allows you to filter out all unwanted structures. (After they got loaded).
+- Are the Scrolling which also works with the Mouseweel.

Now to the Entries in the List:
Type Defines what structure it is.
BlockX &Z tell you were it is located at. (its as accurate as mcs locate command)
Will Generate will show you if the Structure can actually generate in the world. (Yes there are cases where they wont).
Parts tell you hwo many components these structures have. Bigger number bigger structure.

Remove & Remove from world delete the structure out of the file system and also prevent that this structure regenerates even if the chunk is deleted and regenerated. (That can be removed by removing the created save zone.
Remove from world also removes the Structure from the world by deleting these chunks.

The Teleport button just teleports you there.
But that covers it.

Retrogen:


This is the Selection Screen that allows you to select what the retrogen command does.
For those who search for help you just use these commands:
/pregen gen startradius 0 0 100 0 Retrogen
That will toggle the retrogen part.
How that thing operates basically benabling and disabling these Generators in this UI. Thats it.
You can not change it while the Pregenerator runs but its plain & Simple.

Known issues:

  • Big Terrain Gen Mods cause slowdowns in pregeneration speed.
  • The 1.7.10 version is not compatible with Chickenbones Mods but there is a fix mod for that you can install which fixes 1 function in Chickenbones mods that make them compatible again.
    Link: https://minecraft.curseforge.com/projects/chicken-chunk-patcher
  • RTG is 50% incompatible with this Pregeneration Tool, you still can do terrain only generation with my tool and RTG but if you try to use a full generation half of the terrain will not generate because RTG changes how chunks should be generating which is much slower and harder to pull of to work properly in their mod. So its unfixable for me. As long you do terrain only you are fine!
  • Thaumcraft 6: Thaumcraft uses a Special way to generate Aura. The way he is doing that is no longer supported since my tool would lose around 40-60% Speed by just throwing these events.
    And yes its compatible with all other mods   (Seems to be fixed on Thaumcrafts side. I leave it until people confirm that its not fixed or it is fixed)
  • Sponge-Forge: Chunk Pregenerator has a brute force aproach for Generating a world. Sponge isn't a fan of that since every single action you do needs to be validated and then your mod can do what it wants. But that has a cost of massive performance loss so its not going to be fixed.
    So when you have a sponge server and want to pregenerate, deinstall sponge temporary generate with my tool and then install sponge again. No harm will happen to your world.
    This only effects the generation part of Chunk Pregen. All other features working fine so far with it.

While the process is going you will receive a lot of these messages:

9400/10000 Chunks <41, 11> (Average/t: 2,7), Ram: 798MB

Here is a explaination about this:

  • 9400/10000 Chunks: Current Progress.
  • <41, 11>:  Current Position of the Pregenerator..
  • (Average/t: 2,7): Average Chunk Generation Speed
  • Ram: 798MB: Current Ram usage

 

 Spotlights:

If you want to do your own Spotlight feel free to contact me to ask for infos.
If you have a suggestion or idea post it down i like to get input.


Thanks for reading.
Speiger


Comments

  • To post a comment, please or register a new account.
Posts Quoted:
Reply
Clear All Quotes

About This Project

  • Project ID
    267193
  • Created
    May 8, 2017
  • Last Released File
    Aug 27, 2018
  • Total Downloads
    490,459
  • License

Categories

Members