-- 新UI 動畫 local actionTmp = cc.CSLoader:createTimeline("csb/battleDescription2.csb") csbNode:runAction(actionTmp) actionTmp:gotoFrameAndPlay(0,false) timeline event -- 動畫事件 local function onFrameEvent(frame) if nil == frame then return local str = frame:getEvent() if str == "end" or str == "END" then print("123") actionTmp:play("start", true) actionTmp:setFrameEventCallFunc(onFrameEvent) Similar Posts Design Pattern - Factory Pattern in C++ and Lua Design Pattern - Decorator Pattern in C++ and Lua Design Pattern - Observer Pattern in C++ and Lua Design Pattern - Strategy Pattern in C++ and Lua Blogger教學》Facebook留言同步 手機版?m=1也可同步 (2018/2月已失效) Jekyll及GitHub教學4》SEO優化-讓網站更易被搜尋 Comments
-- 動畫事件 local function onFrameEvent(frame) if nil == frame then return local str = frame:getEvent() if str == "end" or str == "END" then print("123") actionTmp:play("start", true) actionTmp:setFrameEventCallFunc(onFrameEvent) Similar Posts Design Pattern - Factory Pattern in C++ and Lua Design Pattern - Decorator Pattern in C++ and Lua Design Pattern - Observer Pattern in C++ and Lua Design Pattern - Strategy Pattern in C++ and Lua Blogger教學》Facebook留言同步 手機版?m=1也可同步 (2018/2月已失效) Jekyll及GitHub教學4》SEO優化-讓網站更易被搜尋 Comments