This works great. But for some reason it only works when the server is off... I have tried disabling level saving still no dice. How do you get this to work with the sever on?
E2: Okay, got it to start. Hopefully this works. Thanks!
E: NVM, I downloaded the windows 32 version of numpy. Searching fora 64-bit version..
(I have Python 2.6 and Numpy)
Upon starting this I get this error message:
Microsoft Windows [Version 6.1.7600]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
C:\Program Files\Minecraft\OldServs\Hey0'sTest\world>python mce.py
Traceback (most recent call last):
File "mce.py", line 1, in <module>
import mclevel
File "C:\Program Files\Minecraft\OldServs\Hey0'sTest\world\mclevel.py", line 1
12, in <module>
import nbt
File "C:\Program Files\Minecraft\OldServs\Hey0'sTest\world\nbt.py", line 23, i
n <module>
from numpy import array, zeros, uint8, fromstring
File "C:\Python26\lib\site-packages\numpy\__init__.py", line 136, in <module>
import add_newdocs
File "C:\Python26\lib\site-packages\numpy\add_newdocs.py", line 9, in <module>
from numpy.lib import add_newdoc
File "C:\Python26\lib\site-packages\numpy\lib\__init__.py", line 4, in <module
>
from type_check import *
File "C:\Python26\lib\site-packages\numpy\lib\type_check.py", line 8, in <modu
le>
import numpy.core.numeric as _nx
File "C:\Python26\lib\site-packages\numpy\core\__init__.py", line 5, in <modul
e>
import multiarray
ImportError: DLL load failed: %1 is not a valid Win32 application.
C:\Program Files\Minecraft\OldServs\Hey0'sTest\world>
Does this mean I'm unable to use this on Windows 7 64-bit?
The script won't work while the server is running. Whether save is on or off, the server is still using the level.dat in the world directory. Changes made by the script are overwritten by information the server has in memory. The memory has to be saved to disk and the server stopped before mce.py can write permanent changes to the world.
Hey codewarrior, could I bribe you to add a feature to mce? I don't want to just donate a lot and guilt you into it, so I wanted to see if it was cool first. I want to be able to dump all the sign data. The output would have the coordinates of the sign, then each line of text.
I was playing with relight, I think its broken. deleteChunks works using these numbers.
$ python26 mce.py /tmp/testworld relight 0 0 0 10 10 10
INFO:Identifying /tmp/testworld
INFO:Can't read, attempting to open directory
INFO:Saved 0 chunks
INFO:Scanning for chunks...
INFO:Found 56446 chunks.
INFO:Detected Alpha world.
Traceback (most recent call last):
File "mce.py", line 816, in <module>
editor.run();
File "mce.py", line 763, in run
self.processCommand(sys.argv)
File "mce.py", line 799, in processCommand
func(command)
File "mce.py", line 577, in _relight
chunks = itertools.product(range(box.mincx, box.maxcx),range(box.mincz, box.maxcz))
NameError: global name 'itertools' is not defined
global name 'itertools' is not defined
$ python26 --version
Python 2.6.5
One of my admins spawned a block that didn't exist. We were about to have to revert to a backup three hours old and lose a ton of work! Your script saved us from having to do that. THANKS!!!!!
Hey codewarrior, could I bribe you to add a feature to mce? I don't want to just donate a lot and guilt you into it, so I wanted to see if it was cool first. I want to be able to dump all the sign data. The output would have the coordinates of the sign, then each line of text.
That's a great idea. If you're going to use this to annotate an overhead map, I'd love to see the results. I just pushed the new code to the github.
Here, try this:
World4> help dumpSigns
Usage:
dumpSigns [<filename>]
Saves the text and location of every sign in the world to a text file.
With no filename, saves signs to <worldname>.signs
Output is newline-delimited. 5 lines per sign. Coordinates are
on the first line, followed by four lines of sign text. For example:
[229, 118, -15]
"To boldy go
where no man
has gone
before."
Coordinates are ordered the same as point inputs:
[North/South, Down/Up, East/West]
World4> dumpSigns
Dumping signs...
[progress removed]
Dumped 467 signs to World4.signs
World4> ^C
$ head World4.signs
[280, 101, -11]
Shuttle
&
Cargo Bay
Airlock
[278, 97, -10]
Warp Core
Reactor Control
If it works, donate whatever you think it's worth.
One of my admins spawned a block that didn't exist. We were about to have to revert to a backup three hours old and lose a ton of work! Your script saved us from having to do that. THANKS!!!!!
I was this admin. mce saved our server. Sending you 5bux ASAP.
It works! :smile.gif:
I'm not gonna annotate with it, both c10t and overviewer can do that, I just want a nice list I can search, and let my users read for fun, I'm so glad to have this now! Combined with a teleport plugin I'm using, we can just warp right to whereever a given sign is in case it looks funny.
I'm having so much fun with this tool, I did createchunks to create a buffer past my map border to give people a hint not to go there. "Christopher Columbus style" as one of my users put it. Just off the edge of the earth if you explore too far! Now I don't even need a silly adminium wall. I made sure to do like 20 chunks for each buffer, since if its not big enough, it would just draw in the distance.
I also replaced my own shoddy scripts with "prune" in my cron job, I do it just before the backup and c10t map generator.
One last thing! The server kept crashing after doing this, but all those air chunks needed to have relight ran on them and that fixed it, just letting you know.
I realize this is mainly a SMP tool, but it seems like it could be used on Alpha single player maps, so I tried it out.
Not sure if I'm still doing something wrong because it always says the following when I ask for my position in game:
kip27-2:pymclevel kip$ python mce.py ~/Library/Application\ Support/minecraft/saves/World2
INFO:Identifying /Users/kip/Library/Application Support/minecraft/saves/World2
INFO:Can't read, attempting to open directory
INFO:Saved 0 chunks
INFO:Scanning for chunks...
INFO:Found 501 chunks.
INFO:Detected Alpha world.
World2> player
Players:
Player: [0.5, 2.7999999999999998, 0.5]
World2>
If I move my player and then save and exit and fire up mce.py again, I get the same location.
I then created a brand new world, moved the player position a few blocks from the spawn and then saved and exited. Fired up mce.py and did the following.
Sample output:
"We will absolutely not keep in mind what external mapeditors will have to do to read data from the disk, that makes no sense whatsoever." - Grum
that's the most vicious griefing of all
E2: Okay, got it to start. Hopefully this works. Thanks!
E: NVM, I downloaded the windows 32 version of numpy. Searching fora 64-bit version..
(I have Python 2.6 and Numpy)
Upon starting this I get this error message:
Does this mean I'm unable to use this on Windows 7 64-bit?
This Code works while the server is off but not when its on Did I misunderstand and this wont work while the server is online?
replace Rail with Air
"We will absolutely not keep in mind what external mapeditors will have to do to read data from the disk, that makes no sense whatsoever." - Grum
One of my admins spawned a block that didn't exist. We were about to have to revert to a backup three hours old and lose a ton of work! Your script saved us from having to do that. THANKS!!!!!
That's a great idea. If you're going to use this to annotate an overhead map, I'd love to see the results. I just pushed the new code to the github.
Here, try this:
If it works, donate whatever you think it's worth.
"We will absolutely not keep in mind what external mapeditors will have to do to read data from the disk, that makes no sense whatsoever." - Grum
I was this admin. mce saved our server. Sending you 5bux ASAP.
It works! :smile.gif:
I'm not gonna annotate with it, both c10t and overviewer can do that, I just want a nice list I can search, and let my users read for fun, I'm so glad to have this now! Combined with a teleport plugin I'm using, we can just warp right to whereever a given sign is in case it looks funny.
I'm having so much fun with this tool, I did createchunks to create a buffer past my map border to give people a hint not to go there. "Christopher Columbus style" as one of my users put it. Just off the edge of the earth if you explore too far! Now I don't even need a silly adminium wall. I made sure to do like 20 chunks for each buffer, since if its not big enough, it would just draw in the distance.
http://minecraft.nom-nom-nom.us/maps/current.png
I also replaced my own shoddy scripts with "prune" in my cron job, I do it just before the backup and c10t map generator.
One last thing! The server kept crashing after doing this, but all those air chunks needed to have relight ran on them and that fixed it, just letting you know.
Excellent. I hope you find some juicy stuff in there. I just pushed a fix to make sure new empty chunks are created with appropriate lights.
"We will absolutely not keep in mind what external mapeditors will have to do to read data from the disk, that makes no sense whatsoever." - Grum
Not sure if I'm still doing something wrong because it always says the following when I ask for my position in game:
If I move my player and then save and exit and fire up mce.py again, I get the same location.
I then created a brand new world, moved the player position a few blocks from the spawn and then saved and exited. Fired up mce.py and did the following. After quitting and saving from mce.py if I load that world in Minecraft, the player position is apparently inside some block and I suffocate.
I tried run_regression_test.py to see if perhaps I had some version problem, but it passed.
Any guidance would be appreciated, thank you.