Changeset 643


Ignore:
Timestamp:
08/11/10 18:29:52 (9 years ago)
Author:
beliar
Message:

Patch by Beliar

  • Removed local_loaders directory. The files/classes in local_loaders are not needed anymore since the changes they contain to the classes from the fife editor are not needed anymore as the agents are in seperate files. Any class that used these files are now using the original files/classes from fife.
Location:
trunk/game
Files:
1 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/game/parpg_editor.py

    r584 r643  
    1919 
    2020""" 
    21 This program is a hack. To be able to hook into the FIFE map editor load and 
    22 save functionality we have to change the import path. It runs the FIFE 
    23 editor such that our custom loaders and savers are used instead of the stock 
    24 FIFE ones. Ideally the FIFE editor could be extended to support custom loaders 
    25 and savers so we don't have to resort to tricking the editor. :) 
     21This runs the editor in ..\tools\map_editor\run.py 
    2622""" 
    2723 
    2824if __name__ == '__main__': 
    29     # Either FIFE or the editor do not like being passed an absolute 
    30     # path. Maybe a bug? We have to force paths relative to the parpg 
    31     # directory. This also assumes that the parpg directory is at the same 
    32     # level as the FIFE editor. :P 
    3325    parpg_path = os.path.split(os.path.realpath(sys.argv[0]))[0] 
    3426    parpg_dir = parpg_path.split('/')[-1] 
     
    4436    fife_editor_path = os.path.join(parpg_path, '..', 'tools', 'map_editor') 
    4537    os.chdir(fife_editor_path) 
    46     env = os.environ.copy() 
    47     env['PYTHONPATH'] = os.pathsep.join([ 
    48         os.path.join('..', parpg_path, 'editor'), 
    49         os.path.join('..', parpg_path, 'local_loaders') 
    50     ]) 
    51  
    52     os.execve(args[0], args, env) 
     38    os.execv(args[0], args) 
  • trunk/game/scripts/gamemap.py

    r632 r643  
    1818from fife import fife 
    1919 
    20 from local_loaders.loaders import loadMapFile 
     20from fife.extensions.loaders import loadMapFile 
    2121from scripts.common.utils import loadSettings 
    2222 
     
    7878           @return: None""" 
    7979        self.reset() 
    80         self.map = loadMapFile(filename, self.engine, self.model) 
     80        self.map = loadMapFile(filename, self.engine) 
    8181        self.agent_layer = self.map.getLayer('ObjectLayer') 
    8282        self.top_layer = self.map.getLayer('TopLayer')       
  • trunk/game/scripts/gamemodel.py

    r636 r643  
    358358        @param agent: The agent to be added 
    359359        @type agent: dict """ 
    360         from local_loaders.loaders import loadImportFile 
     360        from fife.extensions.loaders import loadImportFile 
    361361        if not self.agents.has_key(namespace): 
    362362            self.agents[namespace] = {} 
Note: See TracChangeset for help on using the changeset viewer.