2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
|
|
|
-- @module AnimationCache
|
2014-03-20 10:21:28 +08:00
|
|
|
-- @extend Ref
|
2014-06-25 17:36:50 +08:00
|
|
|
-- @parent_module cc
|
2014-03-18 15:55:30 +08:00
|
|
|
|
2014-03-10 14:04:58 +08:00
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Returns a Animation that was previously added.<br>
|
|
|
|
-- If the name is not found it will return nil.<br>
|
|
|
|
-- You should retain the returned copy if you are going to use it.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] getAnimation
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #string name
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @return Animation#Animation ret (return value: cc.Animation)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Adds a Animation with a name.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] addAnimation
|
|
|
|
-- @param self
|
|
|
|
-- @param #cc.Animation animation
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #string name
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return AnimationCache#AnimationCache self (return value: cc.AnimationCache)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] init
|
|
|
|
-- @param self
|
|
|
|
-- @return bool#bool ret (return value: bool)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Adds an animation from an NSDictionary<br>
|
|
|
|
-- Make sure that the frames were previously loaded in the SpriteFrameCache.<br>
|
|
|
|
-- param plist The path of the relative file,it use to find the plist path for load SpriteFrames.<br>
|
|
|
|
-- since v1.1
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] addAnimationsWithDictionary
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #map_table dictionary
|
|
|
|
-- @param #string plist
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return AnimationCache#AnimationCache self (return value: cc.AnimationCache)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Deletes a Animation from the cache.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] removeAnimation
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #string name
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return AnimationCache#AnimationCache self (return value: cc.AnimationCache)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Adds an animation from a plist file.<br>
|
|
|
|
-- Make sure that the frames were previously loaded in the SpriteFrameCache.<br>
|
|
|
|
-- since v1.1<br>
|
|
|
|
-- js addAnimations<br>
|
|
|
|
-- lua addAnimations
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] addAnimationsWithFile
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #string plist
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return AnimationCache#AnimationCache self (return value: cc.AnimationCache)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Purges the cache. It releases all the Animation objects and the shared instance.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] destroyInstance
|
|
|
|
-- @param self
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return AnimationCache#AnimationCache self (return value: cc.AnimationCache)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Returns the shared instance of the Animation cache
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] getInstance
|
|
|
|
-- @param self
|
|
|
|
-- @return AnimationCache#AnimationCache ret (return value: cc.AnimationCache)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- js ctor
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#AnimationCache] AnimationCache
|
|
|
|
-- @param self
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return AnimationCache#AnimationCache self (return value: cc.AnimationCache)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
return nil
|