Class cocos.tiles.RegularTesselationMapLayer

layer.Layer --+        
              |        
ScrollableLayer --+    
                  |    
           MapLayer --+
                      |
                     RegularTesselationMapLayer
A class of MapLayer that has a regular array of Cells.

Methods

  get_cell(self, i, j)
Return Cell at cell pos=(i, j).
  __init__(self) (Inherited from cocos.tiles.MapLayer)
  draw(self) (Inherited from cocos.tiles.ScrollableLayer)
  get_visible_cells(self)
Given the current view in map-space pixels, transform it based on the current screen-space transform and figure the region of map-space pixels currently visible.
(Inherited from cocos.tiles.MapLayer)
  set_debug(self, debug) (Inherited from cocos.tiles.MapLayer)
  set_dirty(self) (Inherited from cocos.tiles.MapLayer)
  set_view(self, x, y, w, h) (Inherited from cocos.tiles.MapLayer)

Class Variables

  debug = False (Inherited from cocos.tiles.MapLayer)
  origin_x = 0 (Inherited from cocos.tiles.ScrollableLayer)
  origin_y = 0 (Inherited from cocos.tiles.ScrollableLayer)
  origin_z = 0 (Inherited from cocos.tiles.ScrollableLayer)

Method Details

get_cell

get_cell(self, i, j)

Return Cell at cell pos=(i, j).

Return None if out of bounds.