Browse Source

Uh, oh, let's keep backward compatibility for base.mainDir

rdb 16 years ago
parent
commit
381f89d8ea
1 changed files with 3 additions and 0 deletions
  1. 3 0
      direct/src/showbase/ShowBase.py

+ 3 - 0
direct/src/showbase/ShowBase.py

@@ -59,6 +59,9 @@ class ShowBase(DirectObject.DirectObject):
         if config.GetBool('want-variable-dump', 0):
         if config.GetBool('want-variable-dump', 0):
             ExceptionVarDump.install()
             ExceptionVarDump.install()
 
 
+        # Locate the directory containing the main program
+        self.mainDir = ExecutionEnvironment.getEnvironmentVariable("MAIN_DIR")
+
         # The appRunner should have been created by the time ShowBase
         # The appRunner should have been created by the time ShowBase
         # has been.
         # has been.
         self.appRunner = AppRunnerGlobal.appRunner
         self.appRunner = AppRunnerGlobal.appRunner