对于非视网膜使用此代码请帮助如何在 ipad 中制作视网膜显示
<?xml version="1.0" encoding="UTF-8"?>
<map version="1.0" orientation="orthogonal" width="21" height="16" tilewidth="49" tileheight="48">
<tileset firstgid="1" name="FirstLevel-ipad" tilewidth="49" tileheight="48">
<image source="FirstLevel-ipad.png" width="256" height="256"/>
<tile id="0">
<properties>
<property name="Award" value=""/>
</properties>
</tile>
<tile id="1">
对于视网膜我试过
<?xml version="1.0" encoding="UTF-8"?>
<map version="1.0" orientation="orthogonal" width="21" height="16" tilewidth="98" tileheight="96">
<tileset firstgid="1" name="FirstLevel-ipadhd" tilewidth="98" tileheight="96">
<image source="FirstLevel-ipadhd.png" width="512" height="512"/>
<tile id="0">
<properties>
<property name="Award" value=""/>
</properties>
项目相关代码
_tileMap = [CCTMXTiledMap tiledMapWithTMXFile:@"FifthLevel.tmx"];
[self addChild:_tileMap];
_objectLayer = [_tileMap layerNamed:@"Objects"];
_dynamicLayer = [_tileMap layerNamed:@"Dynamic"];
//_coinsLayer = [_tileMap layerNamed:@"Coins"];
_keyLayer = [_tileMap layerNamed:@"Key"];
_shadowLayer = [_tileMap layerNamed:@"Shadow"];
_blastedLayer =[_tileMap layerNamed:@"Blasted"];