Uploaded image for project: 'Spigot'
  1. Spigot
  2. SPIGOT-4397

isChunkGenerated method

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Minor Minor
    • None
    • None
    • None
    • This is an API suggestion. The environment where this would prove useful is chunk work, especially chunk pregeneration.

       

    • git-Spigot-f823ac5-020b495 (MC: 113.1) (Implementing API version 1.13.1-R0.1-SNAPSHOT)
    • Yes

      Some plugins may have to work with chunk loading, and chunk pregeneration (which is a way many server owners do to improve performance before the server is released to the public). 

       

      Currently, plugin developers have only 2 ways to check if a chunk has already been generated or is currently loaded:
      > Using the loadchunk method with generate set to false and check if the chunk if the chunk is null. That's not efficient because for pregeneration, you don't want to load already generated chunks. 

      {{loadChunk​(int x, int z, boolean generate)}}

       

      > Using NMS which is version dependent and will necessitate adjusting for all versions. 

       

      Past versions had a easy to use NMS version, but the current version necessitates much more work to be able to get access to the world; and due to the complexity of the workaround, it's reliability over multiple versions is not that great.

       

            md_5 md_5
            Stefatorus Stefan Deleanu
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: