Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

pmimporter: Map conversion tool

Comments in 'Tools' started by aliuly, Mar 17, 2015.

  1. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    I wrote this handy map conversion tool. Allows me to import:

    • MCPC Anvil worlds
    • MCPC McRegion worlds
    • Minecraft PE v0.8.2 (or before) worlds.
    • PocketMine-MP v1.3 worlds.
    You can download it from: Github

    It's main feature is that it will delete/convert blocks. I.e. blocks that are valid in PC edition but are not valid with Pocket Edition that normally cause the client to crash, with this tool, they are either deleted or converted to another block type.

    For more information see the README file.

    Conversion speeds are low, so please be patient.
    Last edited: Apr 3, 2015
    owenscott, djpecraft, Falk and 8 others like this.
  2. Pman1220
    Offline

    Pman1220 Active Member Plugin Developer

    Joined:
    Nov 21, 2013
    Posts:
    123
    Plugins:
    1
    Minecraft User:
    Pman1220
    Very Useful!
  3. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    Thank you. I have just published a small update.

    * Added pmentity to dump entity data
    * Added region settings to MCPE0.2.0 and PMF1.3 formats.
    * Fixed offset functionality.
    * Filter out Dropped Item entities.
  4. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    BTW, in case you didn't notice, if you add the pmimporter.phar to your PocketMine plugins directory it will load as a plugin called ImportMap. This provides with a "/im" command to import maps. However, I myself just use it from the command line.
  5. Goerick
    Offline

    Goerick Active Member

    Joined:
    Jan 24, 2014
    Posts:
    250
    Minecraft User:
    goerick
    What about later infinite maps?
  6. Goerick
    Offline

    Goerick Active Member

    Joined:
    Jan 24, 2014
    Posts:
    250
    Minecraft User:
    goerick
    Maybe take the existing chunks in the map and convert them?
  7. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    No sorry, LevelDB maps (MCPE 0.9.0 or later) are not supported.

    The documentation on LevelDB that I could find is currently poor, and also the PHP LevelDB extension is only available on Linux.
    Radix likes this.
  8. xFlare
    Offline

    xFlare Active Member Plugin Developer

    Joined:
    Sep 28, 2014
    Posts:
    199
    Plugins:
    1
    Minecraft User:
    xFlare
    I'm going to try this, if it works,
    Help?
    CMD> '/Users/flower/Desktop/Flare/bin/php5/bin/php' '/Users/flower/Desktop/Flare/plugins/ImportMap_v2.1-<PMIMPORTER>.phar' 'pmconvert' '-c' '/Users/flower/Desktop/Flare/plugins/ImportMap/rules.txt' '-f' 'mcregion' '/Users/flower/Desktop/way/' '/Users/flower/Desktop/Flare/worlds/as/'

    Failed loading /Users/flower/desktop/SFB/bin/php5/lib/php/extensions/no-debug-zts-20131226/opcache.so: dlopen(/Users/flower/desktop/SFB/bin/php5/lib/php/extensions/no-debug-zts-20131226/opcache.so, 9): image not found

    PocketMine-MP plugin ImportMap v2.1-<PMIMPORTER>

    This file has been generated using DevTools v1.8.0 at Wed, 01 Apr 2015 01:07:00 +0000

    ----------------

    Name: ImportMap

    Version: 2.1-<PMIMPORTER>

    Main: ImportMap\Main

    Api: 1.10.0

    Depend:

    Description: Import Maps

    Authors: aliuly

    Website:

    CreationDate: 1427850420
  9. Goerick
    Offline

    Goerick Active Member

    Joined:
    Jan 24, 2014
    Posts:
    250
    Minecraft User:
    goerick
    Im talking about anvil. Now there is a way to convert db to anvil and thats why... also cant you just make a converter using anvil/mcregion so we can directly convert pc maps... PM reads mcregion maps...
  10. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    In the first post it says:

    MCPC here means Minecraft PC Edition. So yes, Anvil and McRegion formats are supported. I have downloaded several maps for PC editions and tested them succesfully. My favorite is minecraftmaps.com.
  11. xFlare
    Offline

    xFlare Active Member Plugin Developer

    Joined:
    Sep 28, 2014
    Posts:
    199
    Plugins:
    1
    Minecraft User:
    xFlare
    Does this plugin convert Anvil > MCRegion? If so, how?
  12. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    Are you using MacOS? I haven't tested it there.

    Also, it looks like you are using DevTools. The source can be found in my Github repository. You must use the build.php there to create the phar file, otherwise it will not work. Also, the plugin only works as a phar file, not as a source/folder plugin from DevTools.

    I don't know why it is trying to use the opcache.
  13. xFlare
    Offline

    xFlare Active Member Plugin Developer

    Joined:
    Sep 28, 2014
    Posts:
    199
    Plugins:
    1
    Minecraft User:
    xFlare
    Yes, I'm using mac.

    I used devtools to complile the folder named "plugin"
  14. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    xFlare, if you can get a command line you could enter there:

    /Users/flower/Desktop/Flare/bin/php5/bin/php /Users/flower/Desktop/Flare/plugins/pmimporter.phar pmconvert '/Users/flower/Desktop/way/' '/Users/flower/Desktop/Flare/worlds/as/'

    Where '/Users/flower/Desktop/way/' is the Anvil world folder (it should contain a level.dat file for example).
  15. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    Sorry, that wouldn't work. The build.php is required. What happens is that the phar file is used to execute a new pmimporter process. This is to avoid blocking the PocketMine-MP server. Doing a devtool phar file misses all the stuff that pmimporter requires.
  16. xFlare
    Offline

    xFlare Active Member Plugin Developer

    Joined:
    Sep 28, 2014
    Posts:
    199
    Plugins:
    1
    Minecraft User:
    xFlare
    Here is what i'm puting, I want to convert this map called "way" to MCRegion:

    im /Users/flower/Desktop/Moon as waycrash
  17. xFlare
    Offline

    xFlare Active Member Plugin Developer

    Joined:
    Sep 28, 2014
    Posts:
    199
    Plugins:
    1
    Minecraft User:
    xFlare
    Ok I added the build.php next to do pocketmine.yml file.
  18. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    I am afraid I wasn't clear. What you do is go to the source directory for pmimporter and enter:

    Code:
    /Users/flower/Desktop/Flare/bin/php5/bin/php build.php
    That will create a new pmimporter.phar file which then you place in the PocketMine-MP plugin folder.

    To make sure that the plugin works enter:

    Code:
    /im version
    It should show:

    Code:
    pmimporter #.#rel
    Then you would do:

    Code:
    /im /Users/flower/Desktop/way crash
    That will start the conversion process which is very slow. Eventually you will get a converted map called crash.
    Last edited: Apr 1, 2015
  19. xFlare
    Offline

    xFlare Active Member Plugin Developer

    Joined:
    Sep 28, 2014
    Posts:
    199
    Plugins:
    1
    Minecraft User:
    xFlare
    Failed loading /Users/flower/desktop/SFB/bin/php5/lib/php/extensions/no-debug-zts-20131226/opcache.so: dlopen(/Users/flower/desktop/SFB/bin/php5/lib/php/extensions/no-debug-zts-20131226/opcache.so, 9): image not found

    /Users/flower/Desktop/Flare/bin/php5/bin/php build.php
  20. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    Can you try disabling opcache?

Share This Page

Advertisement