Mercurial > traipse_dev
diff orpg/dirpath/__init__.py @ 14:0b8b7e3ed78d traipse_dev
Adding fixes from OpenRPG 1.8.0
Includes GUI patch for Linux users, init2 plugin, cherrypy XML refrence
Completely removes approot from the startup process and creates a software
cleanup process as well.
author | sirebral |
---|---|
date | Mon, 20 Jul 2009 21:25:13 -0500 |
parents | 4385a7d0efd1 |
children | bf799efe7a8a |
line wrap: on
line diff
--- a/orpg/dirpath/__init__.py Sat Jul 18 11:08:53 2009 -0500 +++ b/orpg/dirpath/__init__.py Mon Jul 20 21:25:13 2009 -0500 @@ -10,7 +10,11 @@ # ----------------------------- # * Reworked path verification process to attempt to fall back on the # current working directory if approot fails to verify before -# asking the user to locate the root directory -- Snowdog 12-20-05 +# asking the user to locate the root directory -- Snowdog 12-20-05 +# ----------------------------- +# * Removed reference to approot. It was a superflous creation that carried an object +# that dirpath_tools already creates. It wasted system resources by creating a files +# and by referencing a file to fill an object that was already created. -- SirEbral 07-19-09 import sys import os @@ -18,16 +22,11 @@ root_dir = None -try: - import approot - root_dir = approot.basedir -except: - #attempt to load default path - t = __file__.split(os.sep) - if len(t) > 2: - root_dir = os.sep.join(t[:-3]) - else: - root_dir = os.getcwd() #default ORPG root dir +t = __file__.split(os.sep) +if len(t) > 2: + root_dir = os.sep.join(t[:-3]) +else: + root_dir = os.getcwd() #default ORPG root dir dir_struct = {} @@ -43,4 +42,4 @@ clean = str.replace(clean,'\\','/') print "Rooting OpenRPG at: " + clean -load_paths(dir_struct, root_dir) \ No newline at end of file +load_paths(dir_struct, root_dir)