1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Same world generates every time

Discussion in 'Help' started by Owningle, Dec 9, 2018.

  1. Owningle

    Owningle Spider

    Messages:
    6
    Hello, I'm having an issue where PocketMine will generate the same world every time, no matter the seed. I have tried re installing, and deleting the world.
    Version of PocketMine: 3.4.1
    Version of PHP: 7.2
     
  2. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    Make sure the seed isn't overridden in your pocketmine.yml. If you have a pocketmine.yml worlds option which has the same name as in server.properties, the pocketmine.yml one will take preference.
     
  3. Owningle

    Owningle Spider

    Messages:
    6
    Didn't have that option enabled in the pocketmine.yml, but i turned it on and tried with the same seed, still just generates the same world over and over sadly, looks like a world from a version of mcpe a long time ago

    EDIT:
    looks like this guy had the same issue, although this thread is from a long time ago
    https://forums.pmmp.io/threads/world-generator-help.3674/
     
  4. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    That's strange indeed. What's your system information (PHP version, OS etc) ?
     
  5. Destroyer57

    Destroyer57 Zombie

    Messages:
    275
    Delete pocketmine.yml i had this problem once and it didnt generate same level after i deleted it
     
  6. Owningle

    Owningle Spider

    Messages:
    6
    Still generates the same world for me sadly

    Running windows 10 Pro, PHP 7.2, PocketMine 3.4.1
    CPU: i7 7700k
    RAM: 16GB
    Other specs don't affect this i don't think
     
  7. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    and this is happening on a freshly installed server? I have a machine with near enough the same spec, so I should be able to reproduce it if there is indeed a bug to be found.
     
  8. Owningle

    Owningle Spider

    Messages:
    6
    Completely fresh server, It doesn't seem to generate a world, just see there isn't one and then prepare spawn area.
    First run console output: https://pastebin.com/SFmsDpPU
     
  9. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    Please try generating the world a few times. Each time, write `seed` in the console and record the number. Paste the output here.
     
  10. Owningle

    Owningle Spider

    Messages:
    6
    Run Number, Seed
    1, 599392444
    2, 114766711
    3, 1986277008
    4, -1850566109
    5, 1138979751
     
  11. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    Is the world always block-for-block identical or just similar-looking?
     
  12. Owningle

    Owningle Spider

    Messages:
    6
    At first i thought it was block to block identical, as every world looked identical. but after testing, (teleported myself to 1 65 1) after making a new world a few times, it seems i was wrong, i assumed it was the same world because i could nearly always see every biome close together, and the desert biome doesnt have any cactus, and there are no flowers at all, so it looked like a world from a previous mcpe version.
    Is that normal?

    EDIT: its almost as if the biome layout is the same everytime, but the terain is slightly different
     
  13. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    The terrain generator is currently very basic, so similarities are to be expected. I don't know why the biome generation would be the same though.
     
  14. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    Please paste the following into a .php file in your plugins/ folder and run the server. It'll output a series of numbers. Please copy the numbers here.

    PHP:
    <?php
    /**
     * @name rngtest
     * @main dktapps\rngtest\Main
     * @api 3.0.0
     * @version 1.0.0
     */

    declare(strict_types=1);

    namespace 
    dktapps\rngtest;

    use 
    pocketmine\plugin\PluginBase;

    class 
    Main extends PluginBase{
        public function 
    onLoad(){
            
    $rngs = [
                new \
    pocketmine\utils\Random(599392444),
                new \
    pocketmine\utils\Random(114766711)
            ];

            for(
    $i 0$i 20; ++$i){
                foreach(
    $rngs as $k => $rng){
                    echo 
    $rng->nextSignedInt() . " ";
                }
                echo 
    PHP_EOL;
            }
        }
    }
     
  15. Primus

    Primus Zombie Pigman

    Messages:
    749
    PocketMine worlds are very repetitive. I implemented the noise generator from nukkit and the world immediately looked somewhat (a lot) closer to vanilla. The Random class is working just fine, I tested it a lot. Could be that the strange ellipse biomes are caused by BiomeSelector and the way it "precalculates" the biomes.

    PHP:
    public function recalculate() : void{
            
    $this->map = new \SplFixedArray(64 64);

            for(
    $i 0$i 64; ++$i){
                for(
    $j 0$j 64; ++$j){
                    
    $biome Biome::getBiome($this->lookup($i 63$j 63));
                    if(
    $biome instanceof UnknownBiome){
                        throw new \
    RuntimeException("Unknown biome returned by selector with ID " $biome->getId());
                    }
                    
    $this->map[$i + ($j << 6)] = $biome;
                }
            }
        }
    As @dktapps said: "The terrain generator is currently very basic". Take example this
    PHP:
    // Inside pocketmine/generator/object/Tree.php
    case WoodType::DARK_OAK:
                    return; 
    //TODO
                
    default:
                    
    $tree = new OakTree();
                    
    /*if($random->nextRange(0, 9) === 0){
                        $tree = new BigTree();
                    }else{*/

                    //}
                    
    break;
    Even basis of tree generation is not done.

    And this is how many biomes are currently in pmmp world
    PHP:
    self::register(self::OCEAN, new OceanBiome());
            
    self::register(self::PLAINS, new PlainBiome());
            
    self::register(self::DESERT, new DesertBiome());
            
    self::register(self::MOUNTAINS, new MountainsBiome());
            
    self::register(self::FOREST, new ForestBiome());
            
    self::register(self::TAIGA, new TaigaBiome());
            
    self::register(self::SWAMP, new SwampBiome());
            
    self::register(self::RIVER, new RiverBiome());

            
    self::register(self::ICE_PLAINS, new IcePlainsBiome());


            
    self::register(self::SMALL_MOUNTAINS, new SmallMountainsBiome());

            
    self::register(self::BIRCH_FOREST, new ForestBiome(ForestBiome::TYPE_BIRCH));
    Note: no biome mutations.

    Don't blame Simplex, it's working flawlessly :)
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.