Added docstrings to all contrib scripts
This commit is contained in:
@@ -1,3 +1,13 @@
|
||||
"""Simple Benchmarking script.
|
||||
|
||||
Usage and example:
|
||||
|
||||
$ python contrib/benchmark.py World4/
|
||||
Rendering 50 chunks...
|
||||
Took 20.290062 seconds or 0.405801 seconds per chunk, or 2.464261 chunks per second
|
||||
"""
|
||||
|
||||
|
||||
import chunk
|
||||
import world
|
||||
import tempfile
|
||||
@@ -8,12 +18,6 @@ import os
|
||||
import sys
|
||||
import shutil
|
||||
|
||||
# Simple Benchmarking script. Usage and example:
|
||||
|
||||
# $ python contrib/benchmark.py World4/
|
||||
# Rendering 50 chunks...
|
||||
# Took 20.290062 seconds or 0.405801 seconds per chunk, or 2.464261 chunks per second
|
||||
|
||||
|
||||
# create a new, empty, cache dir
|
||||
cachedir = tempfile.mkdtemp(prefix="benchmark_cache", dir=".")
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
"""Produces block counts
|
||||
|
||||
"""
|
||||
|
||||
import world, chunk
|
||||
|
||||
import sys
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
#!/usr/bin/python
|
||||
|
||||
"""Deletes files from the old chunk-based cache"""
|
||||
|
||||
|
||||
usage = "python contrib/%prog [OPTIONS] <World # / Name / Path to World>"
|
||||
|
||||
description = """
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
#!/usr/bin/python
|
||||
|
||||
'''
|
||||
Updates overviewer.dat file sign info
|
||||
|
||||
This script will scan through every chunk looking for signs and write out an
|
||||
updated overviewer.dat file. This can be useful if your overviewer.dat file
|
||||
is either out-of-date or non-existant.
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
import sys
|
||||
|
||||
"""
|
||||
Very basic player.dat inspection script
|
||||
"""
|
||||
|
||||
sys.path.append(".")
|
||||
|
||||
from overviewer_core.nbt import load
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
#!/usr/bin/python
|
||||
|
||||
'''
|
||||
Generate a region list to rerender certain chunks
|
||||
|
||||
This is used to force the regeneration of any chunks that contain a certain
|
||||
blockID. The output is a chunklist file that is suitable to use with the
|
||||
--chunklist option to overviewer.py.
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#!/usr/bin/python
|
||||
|
||||
"Test Render Script"
|
||||
|
||||
import os, shutil, tempfile, time, sys, math, re
|
||||
from subprocess import Popen, PIPE, STDOUT, CalledProcessError
|
||||
from optparse import OptionParser
|
||||
|
||||
@@ -1,5 +1,10 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
'''
|
||||
Validate a region file
|
||||
|
||||
TODO description here'''
|
||||
|
||||
import os.path
|
||||
import sys
|
||||
overviewer_dir = os.path.split(os.path.split(os.path.abspath(__file__))[0])[0]
|
||||
|
||||
Reference in New Issue
Block a user