mirror of
https://github.com/wassname/phaser.git
synced 2026-07-18 12:30:44 +08:00
README update, Loader audio path fix and Tween.isRunning fix.
This commit is contained in:
@@ -332,7 +332,7 @@ Phaser.Loader.prototype = {
|
||||
*
|
||||
* @method Phaser.Loader#audio
|
||||
* @param {string} key - Unique asset key of the audio file.
|
||||
* @param {Array} urls - An array containing the URLs of the audio files, i.e.: [ 'jump.mp3', 'jump.ogg', 'jump.m4a' ].
|
||||
* @param {Array|string} urls - An array containing the URLs of the audio files, i.e.: [ 'jump.mp3', 'jump.ogg', 'jump.m4a' ] or a single string containing just one URL.
|
||||
* @param {boolean} autoDecode - When using Web Audio the audio files can either be decoded at load time or run-time. They can't be played until they are decoded, but this let's you control when that happens. Decoding is a non-blocking async process.
|
||||
*/
|
||||
audio: function (key, urls, autoDecode) {
|
||||
@@ -773,13 +773,15 @@ Phaser.Loader.prototype = {
|
||||
/**
|
||||
* Private method ONLY used by loader.
|
||||
* @method Phaser.Loader#getAudioURL
|
||||
* @param {Description} urls - Description.
|
||||
* @param {array|string} urls - Either an array of audio file URLs or a string containing a single URL path.
|
||||
* @private
|
||||
*/
|
||||
getAudioURL: function (urls) {
|
||||
|
||||
var extension;
|
||||
|
||||
if (typeof urls === 'string') { urls = [urls]; }
|
||||
|
||||
for (var i = 0; i < urls.length; i++)
|
||||
{
|
||||
extension = urls[i].toLowerCase();
|
||||
|
||||
Reference in New Issue
Block a user