phaser/src/math/easing/EaseMap.js

76 lines
2 KiB
JavaScript
Raw Normal View History

2018-02-12 16:01:20 +00:00
/**
* @author Richard Davey <rich@photonstorm.com>
2023-01-02 17:36:27 +00:00
* @copyright 2013-2023 Photon Storm Ltd.
2019-05-10 15:15:04 +00:00
* @license {@link https://opensource.org/licenses/MIT|MIT License}
2018-02-12 16:01:20 +00:00
*/
2017-10-12 11:47:20 +00:00
var Back = require('./back');
var Bounce = require('./bounce');
var Circular = require('./circular');
var Cubic = require('./cubic');
var Elastic = require('./elastic');
var Expo = require('./expo');
var Linear = require('./linear');
var Quadratic = require('./quadratic');
var Quartic = require('./quartic');
var Quintic = require('./quintic');
var Sine = require('./sine');
2017-10-21 02:54:51 +00:00
var Stepped = require('./stepped');
2017-05-09 23:42:59 +00:00
// EaseMap
module.exports = {
2017-05-17 01:43:27 +00:00
Power0: Linear,
2017-05-10 03:29:42 +00:00
Power1: Quadratic.Out,
Power2: Cubic.Out,
Power3: Quartic.Out,
Power4: Quintic.Out,
2017-05-09 23:42:59 +00:00
2017-05-17 01:43:27 +00:00
Linear: Linear,
2017-05-10 03:29:42 +00:00
Quad: Quadratic.Out,
Cubic: Cubic.Out,
Quart: Quartic.Out,
Quint: Quintic.Out,
Sine: Sine.Out,
Expo: Expo.Out,
Circ: Circular.Out,
Elastic: Elastic.Out,
Back: Back.Out,
Bounce: Bounce.Out,
2017-10-21 02:54:51 +00:00
Stepped: Stepped,
2017-05-09 23:42:59 +00:00
'Quad.easeIn': Quadratic.In,
'Cubic.easeIn': Cubic.In,
'Quart.easeIn': Quartic.In,
'Quint.easeIn': Quintic.In,
2017-05-10 03:29:42 +00:00
'Sine.easeIn': Sine.In,
'Expo.easeIn': Expo.In,
2017-05-09 23:42:59 +00:00
'Circ.easeIn': Circular.In,
'Elastic.easeIn': Elastic.In,
'Back.easeIn': Back.In,
'Bounce.easeIn': Bounce.In,
'Quad.easeOut': Quadratic.Out,
'Cubic.easeOut': Cubic.Out,
'Quart.easeOut': Quartic.Out,
'Quint.easeOut': Quintic.Out,
2017-05-10 03:29:42 +00:00
'Sine.easeOut': Sine.Out,
'Expo.easeOut': Expo.Out,
2017-05-09 23:42:59 +00:00
'Circ.easeOut': Circular.Out,
'Elastic.easeOut': Elastic.Out,
'Back.easeOut': Back.Out,
'Bounce.easeOut': Bounce.Out,
'Quad.easeInOut': Quadratic.InOut,
'Cubic.easeInOut': Cubic.InOut,
'Quart.easeInOut': Quartic.InOut,
'Quint.easeInOut': Quintic.InOut,
2017-05-10 03:29:42 +00:00
'Sine.easeInOut': Sine.InOut,
'Expo.easeInOut': Expo.InOut,
2017-05-09 23:42:59 +00:00
'Circ.easeInOut': Circular.InOut,
'Elastic.easeInOut': Elastic.InOut,
'Back.easeInOut': Back.InOut,
'Bounce.easeInOut': Bounce.InOut
};