diff --git a/v3/src/animation/AnimationManager.js b/v3/src/animation/AnimationManager.js deleted file mode 100644 index f5669c6fe..000000000 --- a/v3/src/animation/AnimationManager.js +++ /dev/null @@ -1,298 +0,0 @@ -/** -* @author Richard Davey -* @copyright 2016 Photon Storm Ltd. -* @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License} -*/ - -var Animation = require('./frame/Animation'); -var Map = require('../structs/Map'); -var Pad = require('../utils/string/Pad'); -var GetObjectValue = require('../utils/object/GetObjectValue'); - -/** -* Animations are managed by the global AnimationManager. This is a singleton class that is -* responsible for creating and delivering animations and their corresponding data to Game Objects. -* -* Sprites and other Game Objects get the data they need from the AnimationManager. -* -* Access it via `state.anims`. -* -* @class Phaser.AnimationManager -* @constructor -*/ -var AnimationManager = function (game) -{ - this.game = game; - - this.textureManager = null; - - this.globalTimeScale = 1; - - this.anims = new Map(); -}; - -AnimationManager.prototype.constructor = AnimationManager; - -AnimationManager.prototype = { - - boot: function (textureManager) - { - this.textureManager = textureManager; - }, - - // config format: - // { - // frames: [ - // { key: textureKey, frame: textureFrame }, - // { key: textureKey, frame: textureFrame, duration: float } - // { key: textureKey, frame: textureFrame, visible: boolean } - // { key: textureKey, frame: textureFrame, onUpdate: function } - // ] - // framerate: integer - // duration: float (seconds, optional, ignored if framerate is set) - // skipMissedFrames: boolean - // delay: integer - // repeat: integer (-1 = forever) - // repeatDelay: integer - // yoyo: boolean - // showOnStart: boolean - // hideOnComplete: boolean - // callbackScope: Object - // onStart: function - // onStartParams: array - // onRepeat: function - // onRepeatParams: array - // onUpdate: function - // onUpdateParams: array - // onComplete: function - // onCompleteParams: array - // transitions: [ - // { - // key: string <- key of the animation to blend with, - // frames: [] <- play these frames before starting key - // } - // ] - // } - - add: function (key, animation) - { - if (this.anims.has(key)) - { - console.error('Animation with key', key, 'already exists'); - return; - } - - animation.key = key; - - this.anims.set(key, animation); - - return this; - }, - - create: function (key, config) - { - if (this.anims.has(key)) - { - console.error('Animation with key', key, 'already exists'); - return; - } - - var anim = new Animation(this, key, config); - - this.anims.set(key, anim); - - return anim; - }, - - - - get: function (key) - { - return this.anims.get(key); - }, - - remove: function (key) - { - var anim = this.get(key); - - if (anim) - { - this.anims.delete(key); - } - - return anim; - }, - - // Load an Animation into a Game Objects Animation Component - load: function (child, key, startFrame) - { - var anim = this.get(key); - - if (anim) - { - anim.load(child, startFrame); - } - - return child; - }, - - play: function (key, child) - { - if (!Array.isArray(child)) - { - child = [ child ]; - } - - var anim = this.get(key); - - if (!anim) - { - return; - } - - for (var i = 0; i < child.length; i++) - { - child[i].anims.play(key); - } - - return this; - }, - - staggerPlay: function (key, child, stagger) - { - if (stagger === undefined) { stagger = 0; } - - if (!Array.isArray(child)) - { - child = [ child ]; - } - - var anim = this.get(key); - - if (!anim) - { - return; - } - - for (var i = 0; i < child.length; i++) - { - child[i].anims.delayedPlay(stagger * i, key); - } - - return this; - }, - - generateFrameNumbers: function (key, config) - { - var startFrame = GetObjectValue(config, 'start', 0); - var endFrame = GetObjectValue(config, 'end', -1); - var firstFrame = GetObjectValue(config, 'first', false); - var out = GetObjectValue(config, 'framesArray', []); - - var texture = this.textureManager.get(key); - - if (!texture) - { - return out; - } - - // No endFrame then see if we can get it - - if (endFrame === -1) - { - endFrame = texture.frameTotal; - } - - if (firstFrame && texture.has(firstFrame)) - { - out.push({ key: key, frame: firstFrame }); - } - - for (var i = startFrame; i <= endFrame; i++) - { - if (texture.has(i)) - { - out.push({ key: key, frame: i }); - } - } - - return out; - }, - - /** - * Really handy function for when you are creating arrays of animation data but it's using frame names and not numbers. - * For example imagine you've got 30 frames named: 'explosion_0001-large' to 'explosion_0030-large' - * You could use this function to generate those by doing: Phaser.Animation.generateFrameNames('explosion_', 1, 30, '-large', 4); - * - * @method Phaser.Animation.generateFrameNames - * @static - * @param {string} prefix - The start of the filename. If the filename was 'explosion_0001-large' the prefix would be 'explosion_'. - * @param {number} start - The number to start sequentially counting from. If your frames are named 'explosion_0001' to 'explosion_0034' the start is 1. - * @param {number} stop - The number to count to. If your frames are named 'explosion_0001' to 'explosion_0034' the stop value is 34. - * @param {string} [suffix=''] - The end of the filename. If the filename was 'explosion_0001-large' the prefix would be '-large'. - * @param {number} [zeroPad=0] - The number of zeros to pad the min and max values with. If your frames are named 'explosion_0001' to 'explosion_0034' then the zeroPad is 4. - * @return {string[]} An array of framenames. - */ - generateFrameNames: function (key, config) - { - var prefix = GetObjectValue(config, 'prefix', ''); - var start = GetObjectValue(config, 'start', 0); - var end = GetObjectValue(config, 'end', 0); - var suffix = GetObjectValue(config, 'suffix', ''); - var zeroPad = GetObjectValue(config, 'zeroPad', 0); - var out = GetObjectValue(config, 'framesArray', []); - - var diff = (start < end) ? 1 : -1; - - // Adjust because we use i !== end in the for loop - end += diff; - - var texture = this.textureManager.get(key); - - if (!texture) - { - return out; - } - - for (var i = start; i !== end; i += diff) - { - var frame = prefix + Pad(i, zeroPad, '0', 1) + suffix; - - if (texture.has(frame)) - { - out.push({ key: key, frame: frame }); - } - } - - return out; - }, - - toJSON: function (key) - { - if (key !== undefined) - { - return this.anims.get(key).toJSON(); - } - else - { - var output = { - anims: [], - globalTimeScale: this.globalTimeScale - }; - - this.anims.each(function (key, anim) - { - output.anims.push(anim.toJSON()); - }); - - return output; - } - }, - - destroy: function () - { - // TODO - } -}; - -module.exports = AnimationManager; diff --git a/v3/src/animation/frame/Animation.js b/v3/src/animation/frame/Animation.js index 2f87e23d1..15f92959e 100644 --- a/v3/src/animation/frame/Animation.js +++ b/v3/src/animation/frame/Animation.js @@ -7,6 +7,9 @@ var Animation = function (manager, key, config) this.key = key; + // A frame based animation (as opposed to a bone based animation) + this.type = 'frame'; + // Extract all the frame data into the frames array this.frames = GetFrames(manager.textureManager, GetObjectValue(config, 'frames', [])); @@ -257,7 +260,7 @@ Animation.prototype = { { var output = { key: this.key, - type: 'frame', + type: this.type, frames: [], framerate: this.frameRate, duration: this.duration, diff --git a/v3/src/animation/AnimationFrame.js b/v3/src/animation/frame/Frame.js similarity index 86% rename from v3/src/animation/AnimationFrame.js rename to v3/src/animation/frame/Frame.js index bc8a49455..63fd17896 100644 --- a/v3/src/animation/AnimationFrame.js +++ b/v3/src/animation/frame/Frame.js @@ -1,4 +1,4 @@ -var AnimationFrame = function (textureKey, textureFrame, index, frame) +var Frame = function (textureKey, textureFrame, index, frame) { // The keys into the Texture Manager of the texture + frame this uses this.textureKey = textureKey; @@ -33,9 +33,9 @@ var AnimationFrame = function (textureKey, textureFrame, index, frame) this.visible = false; }; -AnimationFrame.prototype.constructor = AnimationFrame; +Frame.prototype.constructor = Frame; -AnimationFrame.prototype = { +Frame.prototype = { toJSON: function () { @@ -55,4 +55,4 @@ AnimationFrame.prototype = { }; -module.exports = AnimationFrame; +module.exports = Frame; diff --git a/v3/src/animation/frame/GetFrames.js b/v3/src/animation/frame/GetFrames.js index 7c19ddc01..470fcc5a6 100644 --- a/v3/src/animation/frame/GetFrames.js +++ b/v3/src/animation/frame/GetFrames.js @@ -1,4 +1,4 @@ -var AnimationFrame = require('../AnimationFrame'); +var Frame = require('./Frame'); var GetObjectValue = require('../../utils/object/GetObjectValue'); var GetFrames = function (textureManager, frames) @@ -33,7 +33,7 @@ var GetFrames = function (textureManager, frames) var textureFrame = textureManager.getFrame(key, frame); - animationFrame = new AnimationFrame(key, frame, index, textureFrame); + animationFrame = new Frame(key, frame, index, textureFrame); animationFrame.duration = GetObjectValue(item, 'duration', 0); animationFrame.onUpdate = GetObjectValue(item, 'onUpdate', null); diff --git a/v3/src/animation/frame/Delay.js b/v3/src/animation/frame/components/Delay.js similarity index 100% rename from v3/src/animation/frame/Delay.js rename to v3/src/animation/frame/components/Delay.js diff --git a/v3/src/animation/frame/DelayedPlay.js b/v3/src/animation/frame/components/DelayedPlay.js similarity index 100% rename from v3/src/animation/frame/DelayedPlay.js rename to v3/src/animation/frame/components/DelayedPlay.js diff --git a/v3/src/animation/frame/Load.js b/v3/src/animation/frame/components/Load.js similarity index 100% rename from v3/src/animation/frame/Load.js rename to v3/src/animation/frame/components/Load.js diff --git a/v3/src/animation/frame/Pause.js b/v3/src/animation/frame/components/Pause.js similarity index 100% rename from v3/src/animation/frame/Pause.js rename to v3/src/animation/frame/components/Pause.js diff --git a/v3/src/animation/frame/Paused.js b/v3/src/animation/frame/components/Paused.js similarity index 100% rename from v3/src/animation/frame/Paused.js rename to v3/src/animation/frame/components/Paused.js diff --git a/v3/src/animation/frame/Play.js b/v3/src/animation/frame/components/Play.js similarity index 100% rename from v3/src/animation/frame/Play.js rename to v3/src/animation/frame/components/Play.js diff --git a/v3/src/animation/frame/Progress.js b/v3/src/animation/frame/components/Progress.js similarity index 100% rename from v3/src/animation/frame/Progress.js rename to v3/src/animation/frame/components/Progress.js diff --git a/v3/src/animation/frame/Repeat.js b/v3/src/animation/frame/components/Repeat.js similarity index 100% rename from v3/src/animation/frame/Repeat.js rename to v3/src/animation/frame/components/Repeat.js diff --git a/v3/src/animation/frame/RepeatDelay.js b/v3/src/animation/frame/components/RepeatDelay.js similarity index 100% rename from v3/src/animation/frame/RepeatDelay.js rename to v3/src/animation/frame/components/RepeatDelay.js diff --git a/v3/src/animation/frame/Restart.js b/v3/src/animation/frame/components/Restart.js similarity index 100% rename from v3/src/animation/frame/Restart.js rename to v3/src/animation/frame/components/Restart.js diff --git a/v3/src/animation/frame/Resume.js b/v3/src/animation/frame/components/Resume.js similarity index 100% rename from v3/src/animation/frame/Resume.js rename to v3/src/animation/frame/components/Resume.js diff --git a/v3/src/animation/frame/Stop.js b/v3/src/animation/frame/components/Stop.js similarity index 100% rename from v3/src/animation/frame/Stop.js rename to v3/src/animation/frame/components/Stop.js diff --git a/v3/src/animation/frame/TimeScale.js b/v3/src/animation/frame/components/TimeScale.js similarity index 100% rename from v3/src/animation/frame/TimeScale.js rename to v3/src/animation/frame/components/TimeScale.js diff --git a/v3/src/animation/frame/TotalFrames.js b/v3/src/animation/frame/components/TotalFrames.js similarity index 100% rename from v3/src/animation/frame/TotalFrames.js rename to v3/src/animation/frame/components/TotalFrames.js diff --git a/v3/src/animation/frame/TotalProgress.js b/v3/src/animation/frame/components/TotalProgress.js similarity index 100% rename from v3/src/animation/frame/TotalProgress.js rename to v3/src/animation/frame/components/TotalProgress.js diff --git a/v3/src/animation/frame/Update.js b/v3/src/animation/frame/components/Update.js similarity index 100% rename from v3/src/animation/frame/Update.js rename to v3/src/animation/frame/components/Update.js diff --git a/v3/src/animation/frame/UpdateFrame.js b/v3/src/animation/frame/components/UpdateFrame.js similarity index 100% rename from v3/src/animation/frame/UpdateFrame.js rename to v3/src/animation/frame/components/UpdateFrame.js diff --git a/v3/src/animation/frame/Yoyo.js b/v3/src/animation/frame/components/Yoyo.js similarity index 100% rename from v3/src/animation/frame/Yoyo.js rename to v3/src/animation/frame/components/Yoyo.js diff --git a/v3/src/animation/frame/index.js b/v3/src/animation/frame/components/index.js similarity index 88% rename from v3/src/animation/frame/index.js rename to v3/src/animation/frame/components/index.js index b98076ed9..c20f708e0 100644 --- a/v3/src/animation/frame/index.js +++ b/v3/src/animation/frame/components/index.js @@ -1,4 +1,6 @@ -// Phaser.Animation.Frame +// Phaser.Animation.Frame.Components + +// Used by the GameObject Animation Component module.exports = { diff --git a/v3/src/animation/frame/config.json b/v3/src/animation/frame/config.json new file mode 100644 index 000000000..21ba047ec --- /dev/null +++ b/v3/src/animation/frame/config.json @@ -0,0 +1,32 @@ +{ + frames: [ + { key: textureKey, frame: textureFrame }, + { key: textureKey, frame: textureFrame, duration: float }, + { key: textureKey, frame: textureFrame, visible: boolean }, + { key: textureKey, frame: textureFrame, onUpdate: function } + ], + framerate: integer, + duration: float (seconds, optional, ignored if framerate is set), + skipMissedFrames: boolean, + delay: integer, + repeat: integer (-1 = forever), + repeatDelay: integer, + yoyo: boolean, + showOnStart: boolean, + hideOnComplete: boolean, + callbackScope: Object, + onStart: function, + onStartParams: array, + onRepeat: function, + onRepeatParams: array, + onUpdate: function, + onUpdateParams: array, + onComplete: function, + onCompleteParams: array, + transitions: [ + { + key: string <- key of the animation to blend with, + frames: [] <- play these frames before starting key + } + ] +} diff --git a/v3/src/animation/manager/AddAnimation.js b/v3/src/animation/manager/AddAnimation.js new file mode 100644 index 000000000..157502f6e --- /dev/null +++ b/v3/src/animation/manager/AddAnimation.js @@ -0,0 +1,16 @@ +var AddAnimation = function (key, animation) +{ + if (this.anims.has(key)) + { + console.error('Animation with key', key, 'already exists'); + return; + } + + animation.key = key; + + this.anims.set(key, animation); + + return this; +}; + +module.exports = AddAnimation; diff --git a/v3/src/animation/manager/AnimationManager.js b/v3/src/animation/manager/AnimationManager.js new file mode 100644 index 000000000..0592fc4cf --- /dev/null +++ b/v3/src/animation/manager/AnimationManager.js @@ -0,0 +1,57 @@ +/** +* @author Richard Davey +* @copyright 2016 Photon Storm Ltd. +* @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License} +*/ + +var Map = require('../../structs/Map'); + +/** +* Animations are managed by the global AnimationManager. This is a singleton class that is +* responsible for creating and delivering animations and their corresponding data to Game Objects. +* +* Sprites and other Game Objects get the data they need from the AnimationManager. +* +* Access it via `state.anims`. +* +* @class Phaser.AnimationManager +* @constructor +*/ +var AnimationManager = function (game) +{ + this.game = game; + + this.textureManager = null; + + this.globalTimeScale = 1; + + this.anims = new Map(); +}; + +AnimationManager.prototype.constructor = AnimationManager; + +AnimationManager.prototype = { + + boot: function (textureManager) + { + this.textureManager = textureManager; + }, + + add: require('./AddAnimation'), + create: require('./CreateFrameAnimation'), + get: require('./GetAnimation'), + remove: require('./RemoveAnimation'), + load: require('./LoadAnimationToGameObject'), + play: require('./PlayAnimation'), + staggerPlay: require('./StaggerPlayAnimation'), + generateFrameNumbers: require('./GenerateFrameNumbers'), + generateFrameNames: require('./GenerateFrameNames'), + toJSON: require('./ToJSON'), + + destroy: function () + { + // TODO + } +}; + +module.exports = AnimationManager; diff --git a/v3/src/animation/manager/CreateFrameAnimation.js b/v3/src/animation/manager/CreateFrameAnimation.js new file mode 100644 index 000000000..c5621c064 --- /dev/null +++ b/v3/src/animation/manager/CreateFrameAnimation.js @@ -0,0 +1,18 @@ +var Animation = require('../frame/Animation'); + +var CreateFrameAnimation = function (key, config) +{ + if (this.anims.has(key)) + { + console.error('Animation with key', key, 'already exists'); + return; + } + + var anim = new Animation(this, key, config); + + this.anims.set(key, anim); + + return anim; +}; + +module.exports = CreateFrameAnimation; diff --git a/v3/src/animation/manager/GenerateFrameNames.js b/v3/src/animation/manager/GenerateFrameNames.js new file mode 100644 index 000000000..c66b98914 --- /dev/null +++ b/v3/src/animation/manager/GenerateFrameNames.js @@ -0,0 +1,38 @@ +var GetObjectValue = require('../../utils/object/GetObjectValue'); +var Pad = require('../../utils/string/Pad'); + +var GenerateFrameNames = function (key, config) +{ + var prefix = GetObjectValue(config, 'prefix', ''); + var start = GetObjectValue(config, 'start', 0); + var end = GetObjectValue(config, 'end', 0); + var suffix = GetObjectValue(config, 'suffix', ''); + var zeroPad = GetObjectValue(config, 'zeroPad', 0); + var out = GetObjectValue(config, 'framesArray', []); + + var diff = (start < end) ? 1 : -1; + + // Adjust because we use i !== end in the for loop + end += diff; + + var texture = this.textureManager.get(key); + + if (!texture) + { + return out; + } + + for (var i = start; i !== end; i += diff) + { + var frame = prefix + Pad(i, zeroPad, '0', 1) + suffix; + + if (texture.has(frame)) + { + out.push({ key: key, frame: frame }); + } + } + + return out; +}; + +module.exports = GenerateFrameNames; diff --git a/v3/src/animation/manager/GenerateFrameNumbers.js b/v3/src/animation/manager/GenerateFrameNumbers.js new file mode 100644 index 000000000..9ab4e1c43 --- /dev/null +++ b/v3/src/animation/manager/GenerateFrameNumbers.js @@ -0,0 +1,40 @@ +var GetObjectValue = require('../../utils/object/GetObjectValue'); + +var GenerateFrameNumbers = function (key, config) +{ + var startFrame = GetObjectValue(config, 'start', 0); + var endFrame = GetObjectValue(config, 'end', -1); + var firstFrame = GetObjectValue(config, 'first', false); + var out = GetObjectValue(config, 'framesArray', []); + + var texture = this.textureManager.get(key); + + if (!texture) + { + return out; + } + + // No endFrame then see if we can get it + + if (endFrame === -1) + { + endFrame = texture.frameTotal; + } + + if (firstFrame && texture.has(firstFrame)) + { + out.push({ key: key, frame: firstFrame }); + } + + for (var i = startFrame; i <= endFrame; i++) + { + if (texture.has(i)) + { + out.push({ key: key, frame: i }); + } + } + + return out; +}; + +module.exports = GenerateFrameNumbers; diff --git a/v3/src/animation/manager/GetAnimation.js b/v3/src/animation/manager/GetAnimation.js new file mode 100644 index 000000000..303b0f3a6 --- /dev/null +++ b/v3/src/animation/manager/GetAnimation.js @@ -0,0 +1,6 @@ +var GetAnimation = function (key) +{ + return this.anims.get(key); +}; + +module.exports = GetAnimation; diff --git a/v3/src/animation/manager/LoadAnimationToGameObject.js b/v3/src/animation/manager/LoadAnimationToGameObject.js new file mode 100644 index 000000000..0391b12e6 --- /dev/null +++ b/v3/src/animation/manager/LoadAnimationToGameObject.js @@ -0,0 +1,14 @@ +// Load an Animation into a Game Objects Animation Component +var LoadAnimationToGameObject = function (child, key, startFrame) +{ + var anim = this.get(key); + + if (anim) + { + anim.load(child, startFrame); + } + + return child; +}; + +module.exports = LoadAnimationToGameObject; diff --git a/v3/src/animation/manager/PlayAnimation.js b/v3/src/animation/manager/PlayAnimation.js new file mode 100644 index 000000000..308b54a30 --- /dev/null +++ b/v3/src/animation/manager/PlayAnimation.js @@ -0,0 +1,23 @@ +var PlayAnimation = function (key, child) +{ + if (!Array.isArray(child)) + { + child = [ child ]; + } + + var anim = this.get(key); + + if (!anim) + { + return; + } + + for (var i = 0; i < child.length; i++) + { + child[i].anims.play(key); + } + + return this; +}; + +module.exports = PlayAnimation; diff --git a/v3/src/animation/manager/RemoveAnimation.js b/v3/src/animation/manager/RemoveAnimation.js new file mode 100644 index 000000000..ae4cec113 --- /dev/null +++ b/v3/src/animation/manager/RemoveAnimation.js @@ -0,0 +1,13 @@ +var RemoveAnimation = function (key) +{ + var anim = this.get(key); + + if (anim) + { + this.anims.delete(key); + } + + return anim; +}; + +module.exports = RemoveAnimation; diff --git a/v3/src/animation/manager/StaggerPlayAnimation.js b/v3/src/animation/manager/StaggerPlayAnimation.js new file mode 100644 index 000000000..27666a2c9 --- /dev/null +++ b/v3/src/animation/manager/StaggerPlayAnimation.js @@ -0,0 +1,25 @@ +var StaggerPlayAnimation = function (key, child, stagger) +{ + if (stagger === undefined) { stagger = 0; } + + if (!Array.isArray(child)) + { + child = [ child ]; + } + + var anim = this.get(key); + + if (!anim) + { + return; + } + + for (var i = 0; i < child.length; i++) + { + child[i].anims.delayedPlay(stagger * i, key); + } + + return this; +}; + +module.exports = StaggerPlayAnimation; diff --git a/v3/src/animation/manager/ToJSON.js b/v3/src/animation/manager/ToJSON.js new file mode 100644 index 000000000..7fd43f58c --- /dev/null +++ b/v3/src/animation/manager/ToJSON.js @@ -0,0 +1,23 @@ +var ToJSON = function (key) +{ + if (key !== undefined) + { + return this.anims.get(key).toJSON(); + } + else + { + var output = { + anims: [], + globalTimeScale: this.globalTimeScale + }; + + this.anims.each(function (key, anim) + { + output.anims.push(anim.toJSON()); + }); + + return output; + } +}; + +module.exports = ToJSON; diff --git a/v3/src/boot/Game.js b/v3/src/boot/Game.js index 14b759e75..5253eedfd 100644 --- a/v3/src/boot/Game.js +++ b/v3/src/boot/Game.js @@ -15,7 +15,7 @@ var MainLoop = require('./MainLoop'); var CreateRenderer = require('./CreateRenderer'); var GlobalInputManager = require('../input/GlobalInputManager'); var GlobalStateManager = require('../state/GlobalStateManager'); -var AnimationManager = require('../animation/AnimationManager'); +var AnimationManager = require('../animation/manager/AnimationManager'); var TextureManager = require('../textures/TextureManager'); var Data = require('../components/Data'); var Cache = require('../cache/Cache'); diff --git a/v3/src/checksum.js b/v3/src/checksum.js index 47dbaf289..4edda6323 100644 --- a/v3/src/checksum.js +++ b/v3/src/checksum.js @@ -1,4 +1,4 @@ var CHECKSUM = { -build: '314dd020-1f74-11e7-b5ea-2d9635d37e06' +build: 'e7a0e0b0-1f7e-11e7-9f4f-1ff609af3206' }; module.exports = CHECKSUM; \ No newline at end of file diff --git a/v3/src/components/Animation.js b/v3/src/components/Animation.js index 120a07aa9..46a29b3d7 100644 --- a/v3/src/components/Animation.js +++ b/v3/src/components/Animation.js @@ -1,6 +1,6 @@ var Class = require('../utils/Class'); -var Components = require('../animation/frame/'); +var Components = require('../animation/frame/components/'); var Animation = new Class({