Changeset 366 for trunk


Ignore:
Timestamp:
11/03/09 07:42:06 (10 years ago)
Author:
eliedebrauwer
Message:

Ticket #145 Patch by eliedebrauwer: Remove viewport option from the map files and avoid it from being added automatically by modifying the editor savers file. fixes[s:trac, t:145]

Location:
trunk/game
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/game/editor/savers.py

    r335 r366  
    159159            if cam.getLocationRef().getMap().getId() != self.map.getId(): continue 
    160160            cell_dimensions = cam.getCellImageDimensions() 
    161             viewport = cam.getViewPort() 
    162161 
    163162            attrib = { 
     
    171170            } 
    172171 
    173             if viewport != self.engine.getRenderBackend().getArea(): 
    174                 attrib['viewport'] = '%d,%d,%d,%d' % (viewport.x, viewport.y, viewport.w, viewport.h) 
    175                  
    176172            camera_element = Element('camera', attrib) 
    177173            camera_element.tail = "\n" 
  • trunk/game/maps/map.xml

    r361 r366  
    18741874        </layer> 
    18751875 
    1876         <camera id="main" ref_cell_height="38" ref_cell_width="72" ref_layer_id="ObjectLayer" rotation="45.0" tilt="-60.0" viewport="0,0,1024,768" zoom="1.0" /> 
     1876        <camera id="main" ref_cell_height="38" ref_cell_width="72" ref_layer_id="ObjectLayer" rotation="45.0" tilt="-60.0" zoom="1.0" /> 
    18771877</map> 
Note: See TracChangeset for help on using the changeset viewer.