import cocos
from cocos.tiles import load
from cocos.layer import ScrollingManager
from cocos.director import director
from cocos.scene import Scene
director.init()
MapLayer = load("themap.tmx")
scroller = ScrollingManager()
scroller.add(MapLayer)
director.run(Scene(scroller))
刚开始使用 cocos 并试图弄清楚 Tilemaps。得到荒谬的错误,并希望得到一些帮助。