0

useBiomeData is a property of worlds

Rewrite Tracking Issue: ##568
This commit is contained in:
Andrew Chin
2011-12-20 00:53:43 -05:00
parent 2e01a36686
commit 3aa9e49631
2 changed files with 5 additions and 4 deletions

View File

@@ -403,9 +403,6 @@ dir but you forgot to put quotes around the directory, since it contains spaces.
logging.info("Welcome to Minecraft Overviewer!")
logging.debug("Current log level: {0}".format(logging.getLogger().level))
useBiomeData = os.path.exists(os.path.join(worlddir, 'biomes'))
if not useBiomeData:
logging.info("Notice: Not using biome data for tinting")
# make sure that the textures can be found
try:
@@ -417,7 +414,7 @@ dir but you forgot to put quotes around the directory, since it contains spaces.
# First do world-level preprocessing. This scans the world hierarchy, reads
# in the region files and caches chunk modified times, and determines the
# chunk bounds (max and min in both dimensions)
w = world.World(worlddir, destdir, useBiomeData=useBiomeData, regionlist=regionlist, north_direction=north_direction)
w = world.World(worlddir, destdir, regionlist=regionlist, north_direction=north_direction)
if north_direction == 'auto':
north_direction = w.persistentData['north_direction']
options.north_direction = north_direction

View File

@@ -111,6 +111,10 @@ class World(object):
# TODO figure out where to handle regionlists
self.useBiomeData = os.path.exists(os.path.join(worlddir, 'biomes'))
if not self.useBiomeData:
logging.info("Notice: Not using biome data for tinting")
def get_level_dat_data(self):
"""Returns a dictionary representing the level.dat data for this World"""
return nbt.load(os.path.join(self.worlddir, "level.dat"))