Ignore:
Timestamp:
10/11/09 10:34:47 (10 years ago)
Author:
eliedebrauwer
Message:

Ticket #66: Patch by saritor, eliedebrauwer & kaydeth cross map teleporting is now possible, we extended the objects within gamestate to make use of double hashing (f(obj_id,map_id)->object). Going back to a previously loaded map is still broken (camera issue). Also extended map.xml and map2.xml in order to make it possible to go back and forth between these two maps. comment[s:trac, t:66]

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/game/scripts/map.py

    r313 r314  
    113113           @return: None""" 
    114114        # actually this is real easy, we just have to 
    115         # attach the main camera to the PC 
    116         self.cameras['main'].attach(agent) 
     115        # attach the main camera to the PC, if a camera 
     116        # was already used, we simply recycle it.  
     117        if self.cameras['main'].getAttached() == None: 
     118            self.cameras['main'].attach(agent) 
    117119 
    118120    def addObject(self, name, obj): 
     
    132134        renderer = self.cameras['main'].getRenderer(str(r_name)) 
    133135        renderer.setEnabled(not renderer.isEnabled()) 
     136 
Note: See TracChangeset for help on using the changeset viewer.