local MainScene = class("MainScene", function() return display.newScene("MainScene") end) function MainScene:ctor() --单张的不可以 display.addSpriteFrames("bandit.plist", "bandit.png") --添加帧缓存 local sp = display.newSprite("#player_run1.png", 200, 200):addTo(self) local frames = display.newFrames("player_run%1d.png", 1, 6) local animation = display.newAnimation(frames, 2.8/14.0) sp:playAnimationOnce(animation) end return MainScene