Coder Social home page Coder Social logo

matcracker / blocksconverter Goto Github PK

View Code? Open in Web Editor NEW
46.0 9.0 11.0 258 KB

A PocketMine-MP plugin allows you to convert Minecraft PC maps to MCPE/Bedrock maps or vice-versa.

License: GNU General Public License v3.0

PHP 100.00%
conversion minecraft backup pmmp-plugin pocketmine-mp-plugin converter world-converter mcpc-to-mcpe

blocksconverter's Introduction

BlocksConverter

   Discord

BlocksConverter is a PocketMine-MP plugin that allows you to translate blocks from MC: Java Edition to Bedrock or vice-versa.

Supported world conversion

From To Supported
Java 1.13+ PocketMine No
Java 1.12 or lower PocketMine Yes

Important

This plugin could take some time when converting worlds. While the conversion, don't try to stop or turn off the server until it's finished.

Commands

/convert

Allows to convert a single world or a queue of world to the platform destination (bedrock or java).

Syntax: /convert <world_name|queue> [backup=true|false] [platform=bedrock|java] [force=true|false]

Permission: blocksconverter.command.convert

Command parameters:

  • <world_name|queue>: it's a mandatory parameter, it requires the name of world to be converted or "queue" to convert a list of worlds. (See /convertqueue for more information)
  • [backup=true|false]: it's an optional parameter, when the value is "true" it creates a backup of your world before the conversion otherwise not. (Default "true")
  • [platform=bedrock|java]: it's an optional parameter, when the value is "bedrock" it converts the world from java to bedrock, when "java" it converts from bedrock to java. (Default "bedrock")
  • [force=true|false]: it's an optional parameter, when the value is "true" you will force the conversion to run (at your own risk!) otherwise not. (Default "false")

/convertqueue

Allows managing worlds to be converted. It's useful when you need to convert more than one world.

Syntax: /convertqueue <add|remove|status> [world_name|all]

Permission: blocksconverter.command.convertqueue

Command alias: /cq

Command parameters:

  • add: It adds one or all worlds in queue before the conversion.
  • remove: It removes one or all worlds from the queue.
  • status: It shows the status of current queue.

/toolblock

Allows showing information about the block you are targeting. (Useful to detect the block ID to replace with).

Permission: blocksconverter.command.toolblock

blocksconverter's People

Contributors

matcracker avatar poggit-bot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

blocksconverter's Issues

Commands do not implement PluginIdentifiableCommand

This prevents Poggit from detecting the command, and hence the plugin cannot be searched at https://poggit.pmmp.io/cmds

This is not a critical issue, so your plugin is not immediately rejected. However, please make sure this issue is resolved in your next update.

This issue was created via GitHub API automatically, but you are welcome to reply to this issue to contact me. Sorry about not reading the CONTRIBUTING.md in this repo 🙃

Help

Hey I can I get some help? converting a hub java map to mcbe?

Improve world backup system

The backup system is currently very poor. It simply copy the world's folder to the plugin data folder.

What it should do is:
1.To compress the backup (optional)
2. Rename the archive's name with a date and time format

large size map

Looks like your plugin has a limit on the conversion size, doesn't it? . When I convert a large map with size 5000x5000 it doesn't work and gives error. My map has a version lower than 1.12.x. Hope you can help me

This is Bug .

[Server thread/EMERGENCY]: An unrecoverable error has occurred and the server has crashed. Creating a crash dump
[Server thread/EMERGENCY]: Please upload the "C:\Users\NguyenTienDat\OneDrive\SkyFactions\crashdumps/Sat_Sep_11-16.59.08-WIB_2021.log" file to the Crash Archive and submit the link to the Bug Reporting page. Give as much info as you can.

Error when converting World

Error is:

[20:52:40] [Server thread/INFO]: [BlocksConverter] Current analyzed chunks: 5200/20445 (200 chunks/4.3s)
[20:52:55] [Server thread/CRITICAL]: [BlocksConverter] ErrorException: Illegal string offset 'text' in phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/plugins/BlocksConverter_dev-18.phar/src/matcracker/BlocksConverter/world/WorldManager.php:144
Stack trace:
#0 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/plugins/BlocksConverter_dev-18.phar/src/matcracker/BlocksConverter/world/WorldManager.php(144): pocketmine\utils\Utils::errorExceptionHandler(2, 'Illegal string ...', 'phar://C:/Users...', 144, Array)
#1 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/plugins/BlocksConverter_dev-18.phar/src/matcracker/BlocksConverter/commands/Convert.php(56): matcracker\BlocksConverter\world\WorldManager->startConversion()
#2 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/command/SimpleCommandMap.php(270): matcracker\BlocksConverter\commands\Convert->execute(Object(pocketmine\command\ConsoleCommandSender), 'convert', Array)
#3 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/Server.php(2029): pocketmine\command\SimpleCommandMap->dispatch(Object(pocketmine\command\ConsoleCommandSender), 'convert queue')
#4 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/Server.php(1616): pocketmine\Server->dispatchCommand(Object(pocketmine\command\ConsoleCommandSender), 'convert queue')
#5 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/vendor/pocketmine/snooze/src/SleeperHandler.php(123): pocketmine\Server->pocketmine\{closure}()
#6 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/vendor/pocketmine/snooze/src/SleeperHandler.php(85): pocketmine\snooze\SleeperHandler->processNotifications()
#7 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/Server.php(2348): pocketmine\snooze\SleeperHandler->sleepUntil(1569872759.341)
#8 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/Server.php(2205): pocketmine\Server->tickProcessor()
#9 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/Server.php(1784): pocketmine\Server->start()
#10 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/PocketMine.php(275): pocketmine\Server->__construct(Object(BaseClassLoader), Object(pocketmine\utils\MainLogger), 'C:\\Users\\Acer-M...', 'C:\\Users\\Acer-M...')
#11 phar://C:/Users/Acer-Maison/Documents/PocketMine-MP 1.12/PocketMine-MP.phar/src/pocketmine/PocketMine.php(299): pocketmine\server()
#12 C:\Users\Acer-Maison\Documents\PocketMine-MP 1.12\PocketMine-MP.phar(1): require('phar://C:/Users...')
#13 {main}
[20:52:55] [Server thread/INFO]: [BlocksConverter]
--- Conversion Report ---
Status: Aborted
World name: world
Execution time: 415.5 second(s)
Analyzed chunks: 5342
Analyzed sub-chunks: 367234
Blocks converted: 6411
Signs converted: 75
----------

World is: MineCorporation Texture pack + Map (2.0) Neptunox
Pocketmine: 3.9.4
Version of BlocksConverter: DEV #18

[BlocksConverter] ErrorException: Undefined index: color

Issue description

  • Expected Result: World to successfully be converted.

  • Actual result: Process is Aborted with the error [BlocksConverter] ErrorException: Undefined index: color

Steps to reproduce the issue

  1. Start the server
  2. Once loaded type cq add spawn and wait for World "spawn" has been added in queue.
  3. type /convert queue - process starts converting until it's aborted with an error

OS and versions

  • PocketMine-MP: 3.9.4(v1.12.0) (protocol version 361)
  • PHP: 7.3
  • Server OS: Window 10 Pro (Build 18362.10022)
  • Game version: Win10 1.12.1

Plugins

BlocksConverter v2.0.0

Error Message in Console

[23:36:11] [Server thread/CRITICAL]: [BlocksConverter] ErrorException: Undefined index: color in phar://D:/Users/jcgau/Desktop/PMMP/plugins/BlocksConverter.phar/src/matcracker/BlocksConverter/world/WorldManager.php:142 Stack trace: #0 phar://D:/Users/jcgau/Desktop/PMMP/plugins/BlocksConverter.phar/src/matcracker/BlocksConverter/world/WorldManager.php(142): pocketmine\utils\Utils::errorExceptionHandler(8, 'Undefined index...', 'phar://D:/Users...', 142, Array) #1 phar://D:/Users/jcgau/Desktop/PMMP/plugins/BlocksConverter.phar/src/matcracker/BlocksConverter/commands/Convert.php(56): matcracker\BlocksConverter\world\WorldManager->startConversion() #2 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/command/SimpleCommandMap.php(270): matcracker\BlocksConverter\commands\Convert->execute(Object(pocketmine\command\ConsoleCommandSender), 'convert', Array) #3 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/Server.php(2029): pocketmine\command\SimpleCommandMap->dispatch(Object(pocketmine\command\ConsoleCommandSender), 'convert queue') #4 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/Server.php(1616): pocketmine\Server->dispatchCommand(Object(pocketmine\command\ConsoleCommandSender), 'convert queue') #5 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/vendor/pocketmine/snooze/src/SleeperHandler.php(123): pocketmine\Server->pocketmine\{closure}() #6 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/vendor/pocketmine/snooze/src/SleeperHandler.php(85): pocketmine\snooze\SleeperHandler->processNotifications() #7 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/Server.php(2348): pocketmine\snooze\SleeperHandler->sleepUntil(1569652552.2456) #8 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/Server.php(2205): pocketmine\Server->tickProcessor() #9 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/Server.php(1784): pocketmine\Server->start() #10 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/PocketMine.php(275): pocketmine\Server->__construct(Object(BaseClassLoader), Object(pocketmine\utils\MainLogger), 'D:\\Users\\jcgau\\...', 'D:\\Users\\jcgau\\...') #11 phar://D:/Users/jcgau/Desktop/PMMP/PocketMine-MP.phar/src/pocketmine/PocketMine.php(299): pocketmine\server() #12 D:\Users\jcgau\Desktop\PMMP\PocketMine-MP.phar(1): require('phar://D:/Users...') #13 {main} [23:36:11] [Server thread/DEBUG]: [BlocksConverter] Conversion finished! Printing full report... [23:36:11] [Server thread/INFO]: [BlocksConverter] --- Conversion Report --- Status: Aborted World name: spawn Execution time: 19.2 second(s) Analyzed chunks: 1173 Analyzed sub-chunks: 41758 Blocks converted: 3419 Signs converted: 1 ----------

erro conversion

after conversion activator rail still continues in place of the tiles

World is not loaded

Support only 1.13 / 1.8 world ? Because when i used the syntax /convert
or /convert
even if i do /load … not workin world is not loaded

Stained Glass

How can i make it convert stained glass/will this be added?

How it work

When i put the map what commands i do?
Cuz i not understand much this plugin
Ty for reply

How to add more blocks to convert?

Hey,

I tried adding the structure block to the BlocksMap.php to be able to convert that as well. But it’s not doing it. Can you explain how can I add more blocks to convert?

Thanks, Bumy

Not work

image

Not work :P

Config:

settings:
  chunk-radius: 15
blocks:
  44-1:
    converted-id: 158
    converted-data: 0
  44-7:
    converted-id: 44
    converted-data: 6
  125-0:
    converted-id: 157
    converted-data: 1
  126-0:
    converted-id: 44
    converted-data: 1
  166-0:
    converted-id: 95
    converted-data: 0
  188-0:
    converted-id: 85
    converted-data: 1
  189-0:
    converted-id: 85
    converted-data: 2
  191:
    converted-id: 85
    converted-data: 5
  95-0:
    converted-id: 241
    converted-data: 0
  95-1:
    converted-id: 241
    converted-data: 1
  95-2:
    converted-id: 241
    converted-data: 2
  95-3:
    converted-id: 241
    converted-data: 3
  95-4:
    converted-id: 241
    converted-data: 4
  95-5:
    converted-id: 241
    converted-data: 5
  95-6:
    converted-id: 241
    converted-data: 6
  95-7:
    converted-id: 241
    converted-data: 7
  95-8:
    converted-id: 241
    converted-data: 8
  95-9:
    converted-id: 241
    converted-data: 9
  95-10:
    converted-id: 241
    converted-data: 10
  95-11:
    converted-id: 241
    converted-data: 11
  95-12:
    converted-id: 241
    converted-data: 12
  95-13:
    converted-id: 241
    converted-data: 13
  95-14:
    converted-id: 241
    converted-data: 14
...

Errror while converting

When I did "/convert MAP" it got this error:

RuntimeException: "Cannot set tag at "generatorOptions": tried to overwrite pocketmine\nbt\tag\CompoundTag with pocketmine\nbt\tag\StringTag" (EXCEPTION) in "vendor/pocketmine/nbt/src/tag/CompoundTag" at line 139

crash

Hi, it crashes when i try to convert world

15.05 17:53:40 [Server] CRITICAL pocketmine\world\format\io\exception\UnsupportedWorldFormatException: "World "FAR" is in an unsupported format and needs to be upgraded" (EXCEPTION) in "pmsrc/src/world/WorldManager" at line 250
15.05 17:53:40 [Server] INFO --- Stack trace ---
15.05 17:53:40 [Server] INFO #0 plugins/BlocksConverter-PM4/src/matcracker/BlocksConverter/commands/Convert(71): pocketmine\world\WorldManager->loadWorld(string[3] FAR)
15.05 17:53:40 [Server] INFO #1 pmsrc/src/command/SimpleCommandMap(220): matcracker\BlocksConverter\commands\Convert->execute(object pocketmine\console\ConsoleCommandSender#1058021, string[7] convert, array[1])
15.05 17:53:40 [Server] INFO #2 pmsrc/src/Server(1409): pocketmine\command\SimpleCommandMap->dispatch(object pocketmine\console\ConsoleCommandSender#1058021, string[11] convert FAR)
15.05 17:53:40 [Server] INFO #3 pmsrc/src/Server(1041): pocketmine\Server->dispatchCommand(object pocketmine\console\ConsoleCommandSender#1058021, string[11] convert FAR)
15.05 17:53:40 [Server] INFO #4 pmsrc/vendor/pocketmine/snooze/src/SleeperHandler(123): pocketmine\Server->pocketmine\{closure}()
15.05 17:53:40 [Server] INFO #5 pmsrc/vendor/pocketmine/snooze/src/SleeperHandler(82): pocketmine\snooze\SleeperHandler->processNotifications()
15.05 17:53:40 [Server] INFO #6 pmsrc/src/Server(1661): pocketmine\snooze\SleeperHandler->sleepUntil(double 1652630020.8516)
15.05 17:53:40 [Server] INFO #7 pmsrc/src/Server(1047): pocketmine\Server->tickProcessor()
15.05 17:53:40 [Server] INFO #8 pmsrc/src/PocketMine(304): pocketmine\Server->__construct(object BaseClassLoader#2, object pocketmine\utils\MainLogger#3, string[48] /, string[56] /plugins/)
15.05 17:53:40 [Server] INFO #9 pmsrc/src/PocketMine(327): pocketmine\server()
15.05 17:53:40 [Server] INFO #10 pmsrc(11): require(string[92] phar:///PocketMine-MP.phar/src/Po)
15.05 17:53:40 [Server] INFO --- End of exception information ---
15.05 17:53:40 [Server] EMERGENCY An unrecoverable error has occurred and the server has crashed. Creating a crash dump
15.05 17:53:40 [Server] EMERGENCY Please upload the "/crashdumps/Sun_May_15-15.53.40-UTC_2022.log" file to the Crash Archive and submit the link to the Bug Reporting page. Give as much info as you can.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.