2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
class CCTMXLayer : public CCSpriteBatchNode
|
|
|
|
{
|
|
|
|
void setLayerSize(CCSize val);
|
|
|
|
CCSize getLayerSize();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void setMapTileSize(CCSize val);
|
|
|
|
CCSize getMapTileSize();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void setTiles(unsigned int* pval);
|
|
|
|
unsigned int* getTiles();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void setTileSet(CCTMXTilesetInfo* pval);
|
|
|
|
CCTMXTilesetInfo* getTileSet();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void setLayerOrientation(unsigned int val);
|
|
|
|
unsigned int getLayerOrientation();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-04-26 14:32:17 +08:00
|
|
|
void setProperties(CCDictionary* pval);
|
|
|
|
CCDictionary* getProperties();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void releaseMap();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2013-07-22 13:42:58 +08:00
|
|
|
CCSprite* getTileAt(const CCPoint& tileCoordinate);
|
|
|
|
unsigned int getTileGIDAt(const CCPoint& tileCoordinate);
|
2012-08-10 18:14:04 +08:00
|
|
|
void setTileGID(unsigned int gid, const CCPoint& tileCoordinate);
|
|
|
|
void setTileGID(unsigned int gid, const CCPoint& tileCoordinate, ccTMXTileFlags flags);
|
2012-02-02 14:26:38 +08:00
|
|
|
void removeTileAt(CCPoint tileCoordinate);
|
2013-07-22 13:42:58 +08:00
|
|
|
CCPoint getPositionAt(CCPoint tileCoordinate);
|
2013-07-25 19:58:59 +08:00
|
|
|
CCString* getProperty(const char *propertyName) const;
|
2012-02-02 14:26:38 +08:00
|
|
|
void setupTiles();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void setLayerName(const char *layerName);
|
|
|
|
const char* getLayerName();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-06-15 11:46:51 +08:00
|
|
|
static CCTMXLayer * create(CCTMXTilesetInfo *tilesetInfo, CCTMXLayerInfo *layerInfo, CCTMXMapInfo *mapInfo);
|
2012-02-02 14:26:38 +08:00
|
|
|
};
|