UNPKG

phaser

Version:

A fast, free and fun HTML5 Game Framework for Desktop and Mobile web browsers.

36 lines (33 loc) 765 B
/** * @author Richard Davey <rich@photonstorm.com> * @copyright 2018 Photon Storm Ltd. * @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License} */ /** * [description] * * @function Phaser.Tweens.Builders.GetBoolean * @since 3.0.0 * * @param {object} source - [description] * @param {string} key - [description] * @param {*} defaultValue - [description] * * @return {*} [description] */ var GetBoolean = function (source, key, defaultValue) { if (!source) { return defaultValue; } else if (source.hasOwnProperty(key)) { return source[key]; } else { return defaultValue; } }; module.exports = GetBoolean;