photonstorm
269af69da5
Added extra checks to Sound.play to stop it throwing DOM Exception Error 11 if the sound.readyState
wasn't set or the sound was invalid. Also wrapped stop()
call in a
try catch`.
2014-12-17 13:07:19 +00:00
photonstorm
0a86a7ef51
Time.now can no longer be relied upon to contain a timestamp value. If the browser supports requestAnimationFrame then Time.now
will contain the high resolution timer value that rAf generates. Otherwise it will contain the value of Date.now. If you require the actual time value (in milliseconds) then please use Time.time
instead. Note that all Phaser sub-systems that used to rely on Time.now
have been updated, so if you have any code that extends these please be sure to check it.
2014-11-08 20:01:10 +00:00
photonstorm
2657de0daa
Sound.fadeTo allows you to fade the Sound to the given volume over the duration specified (thanks @nickryall #1225 )
2014-10-15 21:48:00 +01:00
Richard Davey
33ebc10570
Merge pull request #1225 from nickryall/dev
...
Phaser.Sound.fadeTo Method
2014-10-15 21:44:42 +01:00
Bobby Wilson
0482684dc8
changed all typeof comparisons from == to ===
2014-10-10 21:52:06 -06:00
nickryall
f5db1b070e
Phaser.Sound.fadeTo Method
2014-10-10 11:03:13 +13:00
photonstorm
506a091257
Sound.allowMultiple allows you to have multiple instances of a single Sound playing at once. This is only useful when running under Web Audio, and we recommend you implement a local pooling system to not flood the sound channels. But it allows for one Sound object to play overlapping times, useful for gun effects and similar ( #1220 )
2014-10-09 14:44:25 +01:00
photonstorm
9e29a58d89
Sound.fadeOut(duration) will fade the Sound to a volume of zero over the duration given. At the end of the fade the Sound will be stopped and Sound.onFadeComplete dispatched.
...
Sound.fadeIn(duration, loop) will start the Sound playing, or restart it if already playing, set its volume to zero and then increase the volume over the duration given until it reaches 1. At the end of the fade the Sound.onFadeComplete event is dispatched.
2014-09-24 06:51:39 +01:00
photonstorm
20551f9129
Lots of jsdocs fixes ready for the new doc generator.
2014-09-16 17:35:08 +01:00
photonstorm
8fec5169f0
Added Sound._muteVolume which stops Firefox and IE9 crashing if you try to unmute a sound that hasn't yet been muted, which can also happen as a result of a game visibility change (thanks @osmanzeki #1108 #1123 )
2014-09-01 03:13:05 +01:00
photonstorm
52ea95d9ce
Sound.restart used to cause the Sound to double-up if it was already playing when called. Now correctly stops the sound before restarting it (thanks @wombatbuddy #1136 )
2014-08-29 01:06:29 +01:00
photonstorm
2293b64c94
Removing debug / console.log output.
2014-07-09 05:49:13 +01:00
Richard Davey
dd11e2a5a9
Merge pull request #840 from villetou/WebAudioExternalNodeFix
...
Web audio external node fix
2014-07-01 16:06:08 +01:00
j0hnskot
5ef8143322
Fixes bug #906
2014-06-24 01:59:44 +03:00
j0hnskot
cb0d9c5a69
Fixes bug #906 by adding a check for isDecoded in the update loop.
2014-06-15 21:27:32 +03:00
j0hnskot
5aec4cff8f
Fixes bug #906 by adding a check for isDecoded in the update loop.
2014-06-15 21:23:13 +03:00
photonstorm
7d436a7dc3
Update to #868
2014-06-05 13:17:32 +01:00
photonstorm
9aa10f7521
Sound.pause will no longer fire a Sound.onStop signal, and the pause values are set before the onPause signal is dispatched (thanks @AnderbergE, fix #868 )
2014-06-05 02:55:20 +01:00
photonstorm
369e2cc2d0
Sound.destroy(true) would call remove on the SoundManager, which in turn would throw a TypeError as it tried to remove the sound events twice (thanks @AnderbergE, fix #874 )
2014-06-05 02:50:53 +01:00
Ville Touronen
2e7c8de118
Fixed connecting to an externalNode in Sound.play() and Sound.resume().
2014-05-21 00:09:46 +03:00
photonstorm
86f6b114e8
Sound.stop on Samsung S4 would randomly throw a DOM error. Wrapped the audio stop in a try/catch (thanks FSDaniel)
2014-05-09 16:39:45 +01:00
photonstorm
6070bc63bc
Sound.play now returns the Sound object (thanks @AnderbergE, fix #802 )
2014-05-07 00:12:41 +01:00
photonstorm
a5cbd8f2a6
Fixed an issue where Sounds that had been paused via game code would un-mute if the game paused and resumed.
2014-04-28 20:30:47 +01:00
photonstorm
ce6215c98a
Improved the docs to do with Sound duration / durationMS and added the extra output to the Debug.soundInfo (issue #630 )
2014-04-28 02:08:19 +01:00
photonstorm
3728f25d68
SoundManager.remove(sound) now lets you remove a sound from the SoundManager, destroying it in the process.
...
Sound.destroy will remove a sound and all local references it holds, optionally removing itself from the SoundManager as well.
2014-04-01 03:38:13 +01:00
photonstorm
407f71b70e
Tidied up Sound.js
2014-04-01 00:40:26 +01:00
Christian Wesselhoeft
61f18b675c
Trim trailing whitespace.
2014-03-25 14:56:04 -07:00
photonstorm
9c8f01cd7f
The volume given in Sound.play now over-rides that set in Sound.addMarker if specified ( fix #623 )
2014-03-21 15:43:59 +00:00
photonstorm
52118be088
Sound.onMarkerComplete event is now dispatched when a marker stops. See Sound.onLoop for a looping marker event (thanks registered99, fixes #500 )
2014-03-02 11:11:20 +00:00
Richard Davey
94133e4c11
Updated Sound.play loop check
2014-02-22 03:05:41 +00:00
photonstorm
0896c2fac7
Updating copyright year and README.
2014-02-05 16:54:59 +00:00
photonstorm
d1cd1df9a5
Lots of fixes and updates to the Button class, InputHandler for snap offsets, Sound looping and Stage scaling.
2013-12-31 17:03:09 +00:00
photonstorm
86f6ddcbc8
Two new particle examples and a group animation example. Also fixed CocoonJS sound issue and Cache sound locked bug.
2013-12-31 03:37:11 +00:00
photonstorm
ce4cf531d4
Added class constructors, fixed Stripshader, added relative Tween example and updated Tween source.
2013-12-30 16:54:00 +00:00
photonstorm
141337bed9
Heavily optimised PixiShader.
2013-11-26 05:13:56 +00:00
photonstorm
299115ca5d
The entire Phaser library has been updated to match the new JSHint configuration.
2013-11-25 04:40:04 +00:00
photonstorm
13a2cc2feb
Updating all files to adhere to the JSHint settings and fixing lots of documentation errors on the way.
2013-11-25 03:13:04 +00:00
photonstorm
155c863d69
New Timer class and scale event updates.
2013-11-24 11:04:58 +00:00
photonstorm
a6fac64248
Loads of issues reported on Github resolved (sprite crop, music resume, etc).
2013-10-24 04:27:28 +01:00
Richard Davey
f832bacfd6
More Docs!
2013-10-03 01:21:08 +01:00
Richard Davey
e85643abf4
Yet more documentation done.
2013-10-02 20:18:24 +01:00
Richard Davey
ca113b85aa
More docs coming on.
2013-10-01 16:39:39 +01:00
Richard Davey
0a98bb67d8
jsdoc blocks added to every file and tidied up.
2013-10-01 15:05:30 +01:00
Richard Davey
305b12d76b
Adding docs.
2013-10-01 15:01:46 +01:00
Richard Davey
16b1913de1
* Fixed issue in Sound.play where if you gave a missing marker it would play the whole sound sprite instead.
...
* Button.setFrames will set the current frame based on the button state immediately.
* InputHandler now creates the _pointerData array on creation and populates with one empty set of values, so pointerOver etc all work before a start call.
* Added Canvas.setUserSelect() to disable touchCallouts and user selections within the canvas.
* When the game boots it will now by default disable user-select and touch action events on the game canvas.
* Loaded.setPreloadSprite now rounds the width/height values and starts from 1. This fixes canvas draw errors in IE9/10 and Firefox.
2013-09-30 17:12:22 +01:00
Richard Davey
8d17e1f963
Sound duration fixes.
2013-09-30 12:17:21 +01:00
Richard Davey
31bbf05ace
* Fixed small bug stopping Tween.pause / resume from resuming correctly when called directly.
...
* Fixed an issue where Tweens.removeAll wasn't clearing tweens in the addition queue.
* Change: When you swap State all active tweens are now purged.
2013-09-30 11:15:50 +01:00
Richard Davey
18c695e9dd
PixiPatch and other 1.0.7 features
2013-09-27 09:57:08 +01:00
Richard Davey
bc02a1a05e
Fixing collision issues
2013-09-23 01:06:09 +01:00
Richard Davey
45426be0bc
Assets update
2013-09-20 23:21:12 +01:00