From 8c162ce89095fe3272df1a358b0dd83bd5cd6802 Mon Sep 17 00:00:00 2001 From: Andrew Brown Date: Sun, 29 Aug 2010 11:37:18 -0400 Subject: [PATCH] Checks for terrain.png in CWD first. Thanks alexjurkiewicz! --- textures.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/textures.py b/textures.py index f2ad7cc..d466bb0 100644 --- a/textures.py +++ b/textures.py @@ -9,6 +9,10 @@ import numpy from PIL import Image, ImageEnhance def _get_terrain_image(): + # Check the current directory for terrain.png first: + if os.path.isfile("terrain.png"): + return Image.open("terrain.png") + if "darwin" in sys.platform: # On Macs, terrain.png could lie at # "/Applications/minecraft/terrain.png" for custom terrain. Try this