0

added a command line interface

This commit is contained in:
Andrew Brown
2010-08-27 23:44:29 -04:00
parent 08a86a52ab
commit 8817689276
3 changed files with 81 additions and 7 deletions

View File

@@ -71,6 +71,11 @@ class ChunkRenderer(object):
"""Finds a hash of the block array"""
h = hashlib.md5()
h.update(self.level['Blocks'])
# If the render algorithm changes, change this line to re-generate all
# the chunks automatically:
#h.update("1")
digest = h.hexdigest()
# 6 digits ought to be plenty
return digest[:6]