tools: Slightly modify the ClientBuilder such that the config file path can be overridden by deploy.py

This commit is contained in:
Jeremy Koletar 2014-08-02 18:55:32 -05:00
parent dc69481da1
commit 3f5172ae8e

View file

@ -67,6 +67,8 @@ class ClientBuilder(object):
self.modules = {}
self.path_overrides = {}
self.config_file = os.path.join(self.directory, 'config/public_client.prc')
self.mf = ModuleFinder(sys.path+[self.directory])
from panda3d.direct import DCFile
self.dcf = DCFile()
@ -114,7 +116,7 @@ class ClientBuilder(object):
# Next we need config files...
configData = []
with open(os.path.join(self.directory, 'config/public_client.prc')) as f:
with open(self.config_file) as f:
fd = f.read()
fd = fd.replace('SERVER_VERSION_HERE', self.version)
fd = fd.replace('LANGUAGE_HERE', self.language)