Richard Davey
84c86e23f0
strokePoints has new autoClose argument which strokeEllipse takes advantage of
2017-12-02 01:24:18 +00:00
Michael Hadley
10dfa0a7da
Reverting last change - making it easier to access collision groups from Tileset
2017-12-01 18:57:27 -06:00
Michael Hadley
cff6c11ca0
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-12-01 18:09:00 -06:00
Michael Hadley
8adce2ed2e
Tidying: making it easier to access collision objects from a tile
2017-12-01 18:08:58 -06:00
Michael Hadley
806c9d3237
Stroke ellipse fixes
...
- Circumference points should calculate point based on top left of ellipse
- Graphics missing Ellipse class
- Ellipse stroke not "closed"
2017-12-01 18:05:39 -06:00
Felipe Alfonso
1c689639c1
Removed unnecessary check on setBlendMode
2017-12-01 18:56:44 -03:00
Felipe Alfonso
b1e49059ec
Fixed alpha blending issue with textured renderer
2017-12-01 18:55:27 -03:00
Michael Hadley
195ea19ea7
Extra tilemap method findTile (matches Array.prototype.find)
2017-12-01 13:46:27 -06:00
Michael Hadley
a8fdcbc56b
Small fix: use base tile size for tile <-> XY transforms. This only matters for maps with different size tiles.
2017-12-01 13:26:09 -06:00
Michael Hadley
37767ebde1
Tidy: fix v2 linting errors and move Tiled parser bits into modules
2017-12-01 13:26:09 -06:00
Michael Hadley
ed5cdf0bdb
Tidy up - remove old skipIndexZero property on layers
2017-12-01 13:26:09 -06:00
Michael Hadley
742ff1a439
Internal terminology change to make API clearer: tile.worldXY -> tile.pixelXY
2017-12-01 13:26:09 -06:00
Richard Davey
3a0c276810
preDestroy added and event fix.
2017-12-01 18:19:25 +00:00
Richard Davey
81275a6197
Fixed transform issue with Text padding.
2017-12-01 16:53:02 +00:00
Pavle Goloskokovic
66d216af19
Reading total rate value directly from totalRate property in setRate
2017-12-01 15:41:24 +01:00
Pavle Goloskokovic
a3dbb51d3e
Removed return value for setRate method as it is not needed because that value is now stored in totalRate property
2017-12-01 15:40:35 +01:00
Pavle Goloskokovic
411fdd48b2
Setting totalRate value in setRate method
2017-12-01 15:33:02 +01:00
Pavle Goloskokovic
fe9c9c0819
Added totalRate property to BaseSound class
2017-12-01 15:32:03 +01:00
Pavle Goloskokovic
4721d074e8
Merge remote-tracking branch 'origin/master'
2017-12-01 13:16:59 +01:00
Richard Davey
f2c05d2b0d
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-12-01 03:12:00 +00:00
Richard Davey
d0fb5a69f4
Allows for 'font' and 'fill' overrides
2017-12-01 03:11:57 +00:00
Richard Davey
b393aed2e3
Fixed setPadding and padding value assignment
2017-12-01 03:11:41 +00:00
Richard Davey
025c9dc131
Padding now passed in the style object and avoids double call to updateText
2017-12-01 03:11:23 +00:00
Michael Hadley
01f34e18b7
Recalculate faces: make this reset faces on non-colliding tiles
...
This handles edge cases where things like copy can make a tile become non-colliding w/o reseting faces
2017-11-30 17:19:19 -06:00
Pavle Goloskokovic
42b47d2674
Fixed few references
2017-11-30 22:56:54 +01:00
Pavle Goloskokovic
c1adc63ffd
Merge remote-tracking branch 'origin/master'
2017-11-30 22:16:03 +01:00
Pavle Goloskokovic
786c6913ac
Removing WebAudioSpriteSound class, audio sprite creation logic is generic and can be used in base sound manager class, no need for adding more classes and making class hierarchy more complex
2017-11-30 22:15:47 +01:00
Pavle Goloskokovic
9e90b9eec2
Moved logic for audio sprite creation to BaseSoundManager addAudioSprite method
2017-11-30 22:14:20 +01:00
Felipe Alfonso
ef942fb204
Premultiplied Alpha blending
2017-11-30 16:05:45 -03:00
Michael Hadley
0993af649a
Bug fix: extend from empty object
2017-11-30 12:26:07 -06:00
Pavle Goloskokovic
9a3d0a4140
Added hasOwnProperty check for traversing spritemap object
2017-11-30 18:56:38 +01:00
Pavle Goloskokovic
5c3a3ebef2
Improve readability with local variable
2017-11-30 18:56:12 +01:00
Pavle Goloskokovic
9a156ec898
Adding marker for each key in spritemap object
2017-11-30 18:55:21 +01:00
Pavle Goloskokovic
d65cf17a4d
Added spritemap property to WebAudioSpriteSound that holds reference to 'spritemap' object form json file generated by audiosprite tool.
2017-11-30 18:54:27 +01:00
Pavle Goloskokovic
39edc8a9ac
Defaulting config to empty object and calling super method in WebAudioSpriteSound constructor
2017-11-30 18:53:12 +01:00
Pavle Goloskokovic
6412a3c3c2
Added WebAudioSpriteSound class - a Web Audio implementation of audio sprite sound
2017-11-30 18:50:54 +01:00
Pavle Goloskokovic
0bce624170
Merge remote-tracking branch 'origin/master'
2017-11-30 18:18:24 +01:00
Pavle Goloskokovic
1e10ab2f1f
Added case for loading audioSprite files with generic file loader method
2017-11-30 18:18:13 +01:00
Richard Davey
2e7a336ef9
Handling new style settings for fonts and padding.
2017-11-30 17:17:29 +00:00
Richard Davey
5e975eda2c
font has been removed and replaced with fontFamily, fontSize and fontStyle.
...
fill has been replaced with color as it just makes more sense.
2017-11-30 17:17:28 +00:00
Richard Davey
4d71806bea
Text padding is passed to the Text.setPadding method to handle.
2017-11-30 17:17:27 +00:00
Richard Davey
7bd8bf2075
The testString can now be set in the Text config.
2017-11-30 17:17:27 +00:00
Pavle Goloskokovic
c1010bd446
Added support for passing in json object instead of url to json file directly to audioSprite loader method
2017-11-30 18:15:51 +01:00
Michael Hadley
b53f68c84a
Factor layer scale into tile culling
2017-11-30 11:15:35 -06:00
Pavle Goloskokovic
6145ff5869
Loading audioSprite only if audio is enabled and AudioFile instance is returned from AudioFile.create method
2017-11-30 18:12:08 +01:00
Pavle Goloskokovic
1ed35dfc17
Added audioSprite case for handling audio and json files after loading finishes
2017-11-30 18:09:11 +01:00
Pavle Goloskokovic
449ca11ffd
Linking audio and json files when loading audioSprite and setting their linkType to audioSprite
2017-11-30 18:07:27 +01:00
Pavle Goloskokovic
8dc987b7fc
Creating AudioFile in audio loader method and adding it if it's not null
...
Returning loader reference for call chaining
2017-11-30 18:03:16 +01:00
Pavle Goloskokovic
8de108ce68
Returning null of AudioFile instance from AudioFile create method
2017-11-30 18:01:28 +01:00
Pavle Goloskokovic
dc8ef8a148
Added audioSprite multifile loader
2017-11-30 17:59:08 +01:00
Pavle Goloskokovic
5e89c9b1c7
Merge remote-tracking branch 'origin/master'
2017-11-30 16:42:23 +01:00
Michael Hadley
85e75eafa8
Fix for coord transform between world <-> tile + expose tile -> world methods
2017-11-30 09:22:54 -06:00
Pavle Goloskokovic
9ec1fb4cd1
Removing touche events when unlocking only after promise returned from resume method gets resolved
2017-11-30 14:41:46 +01:00
Pavle Goloskokovic
5f21646e6c
Merge remote-tracking branch 'origin/master'
2017-11-30 14:39:33 +01:00
Pavle Goloskokovic
1b94d7eac3
Trying to unlock Web Audio on both touchstart and touchend events
2017-11-30 14:39:24 +01:00
Michael Hadley
bde77f7b95
Blank layers - pass along map's base tile size
2017-11-30 06:56:35 -06:00
Michael Hadley
76b74c677c
Tile culling: use tile's worldXY and w/h so maps with different tileset sizes work
2017-11-30 06:56:13 -06:00
Pavle Goloskokovic
26956d3172
Merge remote-tracking branch 'origin/master'
2017-11-30 13:37:41 +01:00
Pavle Goloskokovic
f692aad1b1
Replaced touchstart with touchend event when unlocking Web Audio
2017-11-30 13:37:31 +01:00
Michael Hadley
a3b8a25521
Allow tilemap to change base tile size for all tiles
2017-11-29 23:16:48 -06:00
Michael Hadley
1be6d7a681
Tilemap & Dynamic: new method for putting a 2D array of tiles at a location
2017-11-29 21:59:11 -06:00
Michael Hadley
e548b73e80
Proper support for multiple tile sizes in a tilemap
...
- Adds base tile size to Tile class. Tiled positions tiles based on the base size.
- Supports proper translation of Tiled's bottom left coord system to Phaser's top left coord for tiles that are bigger or smaller than the base tile size.
- Update static renderer to read position/size from tile
2017-11-29 20:06:52 -06:00
Michael Hadley
2ae4bfa85a
Jsdocs: StaticTilemapLayer & DynamicTilemapLayer
2017-11-29 19:23:42 -06:00
Michael Hadley
36a92d15e7
Add note about ImageCollection being a direct v2 port
2017-11-29 19:23:42 -06:00
Michael Hadley
59cdf89836
Jsdocs: Tilemap
2017-11-29 19:23:42 -06:00
Richard Davey
d1cc12693c
If a GameObject has a preDestroy
method then call it before running the standard destroy calls.
2017-11-30 01:20:22 +00:00
Richard Davey
3964c7a2ac
Added in support for RTL text in the Text Game Object.
2017-11-30 01:20:02 +00:00
Richard Davey
3c8a5b4132
Fixed issue where an array passed in the constructor wasn't properly displayed
...
fix #3094
2017-11-30 00:03:22 +00:00
Richard Davey
309cf610bb
Physics Manager now calls shutdown and destroy.
...
Matter World properly clears out the world and its Engine on shutdown. Also fixed incorrect localWorld.remove calls (fix #3110 )
2017-11-29 23:36:35 +00:00
Richard Davey
31d2262cb4
Fixed HitTest
2017-11-29 23:35:53 +00:00
Richard Davey
a45554d630
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-11-29 22:24:02 +00:00
Richard Davey
a86b68e361
Removed un-needed WorldToCamera, implemented GetWorldPoint across the board
2017-11-29 22:23:58 +00:00
Michael Hadley
d6f8812f49
Jsdoc: Tile
2017-11-29 15:37:23 -06:00
Michael Hadley
a76e270c78
Jsdoc fixup: Number -> Integer, array -> Type[]
2017-11-29 15:07:56 -06:00
Michael Hadley
191f621dad
Jsdocs: Tileset
2017-11-29 14:39:30 -06:00
Michael Hadley
5f3156e2b8
Jsdocs: Tilemap parsing
2017-11-29 14:02:45 -06:00
Michael Hadley
0ee08b76a8
Jsdocs: ParseToTilemap
2017-11-29 13:53:05 -06:00
Michael Hadley
382d8edfcc
Jsdocs: Tilemap Creator & Factor
2017-11-29 13:46:29 -06:00
Michael Hadley
f0e59b3d3d
Blank Layer: remove unnecessary setting of tile size
2017-11-29 13:23:01 -06:00
Michael Hadley
b8695342e1
Prefer UK spelling over US: indices -> indexes
2017-11-29 13:22:30 -06:00
Michael Hadley
80a16065e2
Update to allow multiple tileset sizes within one map
...
Tileset is source of truth for tile size, so this update makes sure that layers are sync'd with the tileset
2017-11-29 12:52:34 -06:00
Michael Hadley
184cfd1979
When creating a Tilemap layer, use Tiled layer offset if no xy specified
2017-11-29 11:59:25 -06:00
Michael Hadley
a7df7c2df9
Tidying up linting, notes and comments
2017-11-29 11:46:19 -06:00
Michael Hadley
f4a6888d86
Tilemap: add method for converting layer from dynamic to static
2017-11-29 11:36:36 -06:00
Michael Hadley
0b4a08730c
Adding debug rendering method to tilemap and layers
2017-11-29 09:05:53 -06:00
Michael Hadley
60f20aa05b
setTileLocationCallback
2017-11-29 08:20:24 -06:00
Michael Hadley
da79734b22
SetTileIndexCallback
2017-11-29 07:53:04 -06:00
Michael Hadley
b4d89fb554
createFromObjects: return an array of sprites
2017-11-29 07:35:26 -06:00
Michael Hadley
a0b4362979
createFromObjects: allow sprite to have any origin while still matching Tiled
2017-11-29 07:25:04 -06:00
Michael Hadley
ee5190660c
Tilemap: upgraded version of createFromObjects from v2
2017-11-28 22:40:48 -06:00
Michael Hadley
e5a8600686
BuildGameObject bug: origin was being set to position xy
2017-11-28 21:57:52 -06:00
Michael Hadley
68634a0deb
Tilemap & layer methods: FilterTiles & CreateFromTiles
2017-11-28 20:49:24 -06:00
Richard Davey
3129950d34
Updated call
2017-11-29 02:25:14 +00:00
Felipe Alfonso
3b296162cf
Camera input transform update
2017-11-28 19:18:05 -03:00
Pavle Goloskokovic
e9a71beba7
Merge remote-tracking branch 'origin/master'
2017-11-28 16:34:48 +01:00
Richard Davey
c58b295fcc
Added positionToCamera method (but still needs fixing)
2017-11-28 11:16:35 +00:00
Richard Davey
e194b95654
PointerConstraint now takes the scene camera it should use as a config option.
2017-11-28 11:16:23 +00:00
Richard Davey
d9a9c7a5a1
esline tidy-up.
2017-11-28 11:15:45 +00:00
Richard Davey
4969bf37e6
The local input manager has a reference to the active pointer.
2017-11-28 11:15:35 +00:00
Richard Davey
f9cda636c5
Added Camera.screenToCamera and setAngle methods.
2017-11-28 11:15:22 +00:00
Pavle Goloskokovic
6f7f5f6144
Merge remote-tracking branch 'origin/master'
2017-11-27 18:13:26 +01:00
Richard Davey
43dbe52e15
Beta 12
2017-11-27 17:02:19 +00:00
Richard Davey
1380af61a1
Added render visible flag.
2017-11-27 17:01:27 +00:00
Pavle Goloskokovic
35e25ab633
Merge remote-tracking branch 'origin/master'
2017-11-27 17:38:51 +01:00
Pavle Goloskokovic
65c30b9f7a
Removed detune property as it is now defined in BaseSoundManager class
2017-11-27 17:38:43 +01:00
Pavle Goloskokovic
e4cebbf29c
Removed rate property as it is now defined in BaseSoundManager class
2017-11-27 17:38:28 +01:00
Pavle Goloskokovic
3c2670a2f9
Removed _detune field as it is now set in BaseSoundManager class
2017-11-27 17:37:41 +01:00
Pavle Goloskokovic
c84a00e248
Removed _rate field as it is now set in BaseSoundManager class
2017-11-27 17:37:11 +01:00
Pavle Goloskokovic
28ae0811e6
Defining detune property in BaseSound class so it can be used in both Web Audio and HTML5 Audio implementations
2017-11-27 17:35:35 +01:00
Pavle Goloskokovic
1c1e75ac85
Defining rate property in BaseSound class so it can be used in both Web Audio and HTML5 Audio implementations
2017-11-27 17:35:09 +01:00
Pavle Goloskokovic
27ad50d276
Setting _detune field in BaseSound class so it can be used in both Web Audio and HTML5 Audio implementations
2017-11-27 17:34:27 +01:00
Pavle Goloskokovic
92ac9d41c5
Setting _rate field in BaseSound class so it can be used in both Web Audio and HTML5 Audio implementations
2017-11-27 17:33:37 +01:00
Pavle Goloskokovic
cf46145d7c
Calling super method in setRate method of WebAudioSound class, setting returned value to source playback rate audio param and returning the same value to match method signature
2017-11-27 17:32:16 +01:00
Pavle Goloskokovic
f389176362
Added setRate method to BaseSound class that contains logic for applying rate and detune settings to sound so it can be reused in both Web Audio and HTML5 Audio implementations
2017-11-27 17:30:55 +01:00
Richard Davey
6da5409688
Added in all of the Composites helpers.
2017-11-27 16:29:43 +00:00
Richard Davey
f24b808ee5
Added setGravity defaults and fixed nextGroup method.
2017-11-27 16:29:33 +00:00
Pavle Goloskokovic
c253e01cac
Merge remote-tracking branch 'origin/master'
2017-11-27 17:22:32 +01:00
Pavle Goloskokovic
881474b7cd
Added a TODO to take into account playback rate when pausing and resuming sound
2017-11-27 16:50:45 +01:00
Pavle Goloskokovic
ffc205b400
Calling setRate method on all sound objects when updating global detune value
2017-11-27 16:50:05 +01:00
Pavle Goloskokovic
c57f692c85
Calling setRate method on all sound objects when updating global rate value
2017-11-27 16:49:28 +01:00
Pavle Goloskokovic
9fffd57ad3
Moved sound source not null check from properties' setter methods to setRate method
2017-11-27 16:48:20 +01:00
Pavle Goloskokovic
db06b3d742
Calling setRate in WebAudioSound detune property's setter method
2017-11-27 16:46:42 +01:00
Pavle Goloskokovic
074c60c270
Calling setRate in WebAudioSound rate property's setter method
2017-11-27 16:45:58 +01:00
Pavle Goloskokovic
1fddd3de2a
Added setRate method to WebAudioSound class that calculates and sets playback rate based on sound's and manager's detune and rate values
2017-11-27 16:44:23 +01:00
Richard Davey
ac9f5c4360
Added quick support for setCircle, setRectangle, setPolygon and setTrapezoid.
2017-11-27 14:48:09 +00:00
Richard Davey
036e7aecc9
If property is undefined fall back to the default value.
2017-11-27 14:48:09 +00:00
Michael Hadley
bd8a2fa39b
More tilemap jsdocs
2017-11-27 07:33:30 -06:00
Michael Hadley
e45bc5c71d
PutTileAt: copy all tile properties from source tile
2017-11-27 07:19:20 -06:00
Richard Davey
da5bb7d199
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-11-27 03:46:10 +00:00
Richard Davey
15a2280813
Added basic Graphics debug, fromPath, isPaused and postUpdate.
2017-11-27 03:45:46 +00:00
Richard Davey
af9f7380e8
Added property
2017-11-27 03:45:12 +00:00
Richard Davey
f8fe81dfa1
New setBody component for setting and change body shape
2017-11-27 03:45:03 +00:00
Richard Davey
ff316be41e
setFriction can now set all 3 values.
2017-11-27 03:44:31 +00:00
Richard Davey
cd629248d0
fix inertia change in Body.setMass
2017-11-26 23:25:49 +00:00
Richard Davey
bccad674b7
fix point
argument of Body.scale
2017-11-26 23:24:16 +00:00
Richard Davey
5862949a4c
fix centroid for static compound bodies
2017-11-26 23:19:45 +00:00
Richard Davey
dc7289e539
Fix Vertices.chamfer radius argument
2017-11-26 23:17:12 +00:00
Pavle Goloskokovic
d13fae2260
Preventing negative values for source start call
2017-11-26 18:12:55 +01:00
Pavle Goloskokovic
150c29a8a0
Merge remote-tracking branch 'origin/master'
2017-11-26 17:25:47 +01:00
Pavle Goloskokovic
93ac04329b
Updated WebAudioSound update method docs and signature
2017-11-26 17:25:01 +01:00
Pavle Goloskokovic
66dcd9f02f
Resetting hasEnded in update method
2017-11-26 17:07:56 +01:00
Pavle Goloskokovic
0a078d26f6
Setting hasEnded when sound ends
2017-11-26 17:07:05 +01:00
Pavle Goloskokovic
f0bc96e68f
Checking hasEnded on update in order to call stop method
2017-11-26 17:05:24 +01:00
Pavle Goloskokovic
84e6459b59
Added hasEnded property to WebAudioSound class
2017-11-26 17:03:36 +01:00
Pavle Goloskokovic
94e834fa96
Updating all sounds on sound manager update
2017-11-26 16:59:12 +01:00
Pavle Goloskokovic
62ca1bef8a
Updating sound manager on game step
2017-11-26 16:45:07 +01:00
Pavle Goloskokovic
ceeef0368c
Added a todo to fix race condition
2017-11-26 16:41:46 +01:00
Pavle Goloskokovic
2995b7eaf6
Added short logic explanation for onended event handler
2017-11-26 16:37:03 +01:00
Pavle Goloskokovic
e13b829ab1
Removed redundant check in onended handler and reverted setting source to null before calling stop() on it since it does not invoke onended event handler immediately
2017-11-26 16:35:13 +01:00
Michael Hadley
dabe3d27ff
Tilemap: more jsdocs
2017-11-26 09:33:19 -06:00
Richard Davey
10d7be0785
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-11-26 15:31:51 +00:00
Richard Davey
3ee14a88a6
Removed referene to Mouse class (no longer used)
2017-11-26 15:31:48 +00:00
Richard Davey
b85b341bfd
Removed references to the Render class (only needed in debug and saved loads of space in the build file)
2017-11-26 15:31:34 +00:00
Pavle Goloskokovic
007a565700
Just checking for null sound reference isn't enough since because calling play() on already playing sound is not covered by that condition
2017-11-26 16:31:06 +01:00
Richard Davey
d4fd2082f2
Removed un-used RenderPixi class
2017-11-26 15:31:04 +00:00
Richard Davey
d1fb8319b2
Removed old module entry point and added license
2017-11-26 15:30:52 +00:00
Richard Davey
f6a5463131
Removed Mouse class from matter.js as it's not used.
2017-11-26 15:30:26 +00:00
Pavle Goloskokovic
aab5150016
Setting source to null before calling stop on it to determine if onended event was fired when sound ended or when it was stopped by user
2017-11-26 16:28:54 +01:00
Pavle Goloskokovic
04eb680d52
Checking if source is null before stopping sound on ended handler because it is called also when stop() method is called on it
2017-11-26 16:27:39 +01:00
Pavle Goloskokovic
1808fab27e
Calling stop method when sound ends
2017-11-26 16:24:49 +01:00
Michael Hadley
80185eb5eb
Fill update: jsdocs & allow fill to update tile collisions + faces
2017-11-26 09:19:57 -06:00
Pavle Goloskokovic
53dbf050d4
Marked a few methods as private
2017-11-26 16:19:56 +01:00
Michael Hadley
09224b724e
Tilemap: adding jsdocs
2017-11-26 09:07:27 -06:00
Richard Davey
1db68dfceb
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-11-26 15:02:49 +00:00
Richard Davey
f4cdd3c1b4
Optimization of Body's hidden class
2017-11-26 15:02:42 +00:00
Michael Hadley
6ca7c9ecfd
Copy update: copy all tile props and recalculate faces within dest region
2017-11-26 08:58:38 -06:00
Richard Davey
dfa3cc243a
Optimization of Resolver.solvePosition method
2017-11-26 14:50:40 +00:00
Pavle Goloskokovic
995f04f34a
Merge remote-tracking branch 'origin/master'
2017-11-26 15:50:18 +01:00
Richard Davey
81b3656d1e
Added Pair.update optimisations and removed the Contact class.
2017-11-26 14:37:17 +00:00
Richard Davey
d2dae2c063
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-11-26 14:05:37 +00:00
Richard Davey
0156f4f927
Fixed order of returns
2017-11-26 14:05:29 +00:00
Michael Hadley
8ec6528d20
Tilemap & layers: replace v2 raycasting with getTilesWithinShape
2017-11-26 07:55:44 -06:00
Michael Hadley
9d29948a02
Update tile culling to factor in the new scale
2017-11-25 20:47:47 -06:00
Michael Hadley
aaa0d41f5d
Fix dynamic layer scale bug
2017-11-25 20:47:20 -06:00
Michael Hadley
c31147df19
Add filtering options to forEachTile, GetTilesWithin, GetTilesWithinWorldXY
2017-11-25 18:03:21 -06:00
Michael Hadley
998ae1bd40
Factor layer scale into WorldToTile calculation
2017-11-25 17:12:24 -06:00
Michael Hadley
b21fc88660
Dynamic Tilemap WebGL - respect layer scale in rendering
2017-11-25 17:09:56 -06:00
Michael Hadley
557ac4fe6e
Add GetTilesWithinWorldXY method to tilemap and layers
2017-11-25 08:42:19 -06:00
Michael Hadley
432c1c0f6d
GetTilesWithin: clip rectangular area to map bounds
2017-11-25 08:40:07 -06:00
Michael Hadley
4c34d09955
Optional snapToFloor parameter added to WorldToTile methods
2017-11-25 07:08:06 -06:00
Michael Hadley
7a90d55dd5
Fix: WorldXY now passes recalculateFaces to TileXY methods
2017-11-25 07:06:14 -06:00
Michael Hadley
7844927256
Image layers added to Tilemap
2017-11-24 09:15:02 -06:00
Michael Hadley
0d02f7d941
Extend Tiled importer to handle offsetx and offsety for the various layers
2017-11-24 08:59:36 -06:00
Michael Hadley
d3aa842bfe
Adding collision prop to Tilemap
2017-11-24 08:23:40 -06:00
Michael Hadley
0e73bae5bc
Extend Tileset to have methods for accessing properties and data per tile
2017-11-24 08:23:22 -06:00
Michael Hadley
805c0a0125
Break Tiled parser into modular pieces & extended capabilities
...
New features:
- Parsing text object
- Parsing "tiles" prop of tileset which contains collision & terrain information
2017-11-24 08:22:55 -06:00
Michael Hadley
fa8178f47b
Port of ImageCollection from v2
2017-11-24 08:21:09 -06:00
Richard Davey
ce28eaaad8
Added the Attractors and Wrap matter plugins. Fixed the Plugin register. Added silence option to stop plugin logging to the console.
2017-11-24 13:42:32 +00:00
Pavle Goloskokovic
a1c98d4831
Merge remote-tracking branch 'origin/master'
2017-11-24 12:50:29 +01:00
Richard Davey
ffeff9d2f7
Added confirmedActive speed optimisation to matter.js and removed Common.indexOf
2017-11-24 00:37:09 +00:00
Felipe Alfonso
f1ea070256
Switched inverted rotation transform
2017-11-23 16:02:41 -03:00
Felipe Alfonso
c6d674af8d
strokeRect fix
2017-11-23 15:53:15 -03:00
Richard Davey
016fda7660
Added imageStack Factory function.
2017-11-23 16:55:28 +00:00
Richard Davey
4723ef0caa
Removed use of Common.indexOf after some horrible perf results.
2017-11-23 16:55:17 +00:00
Richard Davey
1ae7237f73
You can now optionally set if the objects are added to the physics world.
2017-11-23 16:54:55 +00:00
Richard Davey
7c29eab78c
Body has new property: ignorePointer, which pointer checks.
2017-11-23 14:59:26 +00:00
Richard Davey
04df05cf73
World thickness now 128.
2017-11-23 14:59:15 +00:00
Pavle Goloskokovic
762c6cb147
Updated a TODO
2017-11-23 13:55:27 +01:00
Pavle Goloskokovic
266ebc4925
Taking into account marker start time on resuming sound
2017-11-23 13:55:08 +01:00
Pavle Goloskokovic
d369d46e35
Taking into account marker start time if marker is currently played
2017-11-23 13:53:57 +01:00
Pavle Goloskokovic
0ded9af3a9
Resetting current marker if no marker name is provided to play method
2017-11-23 13:52:03 +01:00
Pavle Goloskokovic
5f55931d22
Completed a TODO by setting BaseSound update method to NOOP
2017-11-23 13:19:22 +01:00
Pavle Goloskokovic
a2ceff63f1
Returning marker/null instead of boolean in removeMarker
2017-11-23 13:14:41 +01:00
Pavle Goloskokovic
b3337b6c51
Added validation for non existing marker in removeMarker method
2017-11-23 13:13:25 +01:00
Pavle Goloskokovic
c48f51de35
Setting marker to null on removeMarker call
2017-11-23 13:12:21 +01:00
Pavle Goloskokovic
9d8afee78f
Added validation for non existing marker to updateMarker method
2017-11-23 12:56:32 +01:00
Pavle Goloskokovic
0e97a18553
Added validation for invalid marker name to updateMarker method
2017-11-23 12:56:06 +01:00
Pavle Goloskokovic
42735ee09f
Added validation for when no marker is provided to updateMarker method
2017-11-23 12:55:22 +01:00
Pavle Goloskokovic
17d39f7bab
Merging provided marker with existing marker in updateMarker method
2017-11-23 12:54:47 +01:00
Pavle Goloskokovic
8a4e439b55
Updated logging for addMarker method of BaseSound class
2017-11-23 12:52:19 +01:00
Pavle Goloskokovic
6c38853a6f
Added update marker method to BaseSound class
2017-11-23 12:41:41 +01:00
Pavle Goloskokovic
76a32e20c6
Fixed return values for addMarker method
2017-11-23 12:37:10 +01:00
Pavle Goloskokovic
1e213e6d86
Added validation for existing marker
2017-11-23 12:35:55 +01:00
Pavle Goloskokovic
de5689b129
Added validation for marker name
2017-11-23 12:34:43 +01:00
Pavle Goloskokovic
2bcffe6f2f
Merging provided marker with object with default values
2017-11-23 12:33:56 +01:00
Pavle Goloskokovic
6e8109d812
Merge remote-tracking branch 'origin/master'
2017-11-23 12:31:42 +01:00
Pavle Goloskokovic
40b4dc2e6e
Adding validation and error handling if no marker is passed
2017-11-23 12:31:34 +01:00
Pavle Goloskokovic
084d309efb
Adding market to markers array in addMarker method
2017-11-23 12:30:24 +01:00
Richard Davey
9516e6b188
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-11-23 01:46:02 +00:00
Richard Davey
08047bbdbb
Added the PointerConstraint and Factory methods (aka mouseSpring)
2017-11-23 01:45:58 +00:00
Richard Davey
dbad873236
Added support for beforeUpdate and afterUpdate world events
2017-11-23 01:45:38 +00:00
Richard Davey
b0f2b833c8
Removed two more un-needed files
2017-11-23 01:45:19 +00:00
Richard Davey
4f7a02ef2e
Pointer.position is now a Vec2 and x/y references to it
2017-11-23 01:44:58 +00:00
Pavle Goloskokovic
f48c808698
Merge remote-tracking branch 'origin/master'
2017-11-22 18:13:54 +01:00
Richard Davey
8afa631a38
Added Ignore Gravity component
2017-11-22 17:11:09 +00:00
Pavle Goloskokovic
c1b0bc4ee7
Added a TODO for scheduled playback
2017-11-22 18:07:08 +01:00
Pavle Goloskokovic
068fc6d1c9
Renamed 'marker' param of play method to 'markerName' to avoid any confusion for WebAudioSound
2017-11-22 18:06:21 +01:00
Pavle Goloskokovic
d367dc1a85
Renamed 'marker' param of play method to 'markerName' to avoid any confusion for BaseSound
2017-11-22 18:05:18 +01:00
Pavle Goloskokovic
8e912ab877
Updated currentMarker property to hold reference to marker object instead it's name
2017-11-22 18:03:44 +01:00
Pavle Goloskokovic
55e5041ef8
Setting correct duration value when calling play on BaseSound class
2017-11-22 18:00:53 +01:00
Pavle Goloskokovic
de0aefba7e
Added default value for config in WebAudioSound constructor
2017-11-22 17:58:05 +01:00
Pavle Goloskokovic
9a143694d1
Using duration property instead of config duration setting in WebAudioSound
2017-11-22 17:56:55 +01:00
Pavle Goloskokovic
92abe3f678
Remove completed TODO
2017-11-22 17:54:38 +01:00
Pavle Goloskokovic
ffe4e49512
Setting duration and totalDuration properties in WebAudioSound constructor
2017-11-22 17:54:00 +01:00
Pavle Goloskokovic
90d2e8cf03
Removed setting duration setting in config for WebAudioSound
2017-11-22 17:51:10 +01:00
Pavle Goloskokovic
1296dd737d
Added totalDuration property to BaseSound class
2017-11-22 17:48:10 +01:00
Pavle Goloskokovic
f932e315d6
Added duration property to BaseSound class
2017-11-22 17:47:18 +01:00
Pavle Goloskokovic
7442ab5bc8
Removed duration setting from sound config
2017-11-22 17:45:57 +01:00
Pavle Goloskokovic
f4a1a30565
Merge remote-tracking branch 'origin/master'
2017-11-22 17:45:21 +01:00
Richard Davey
a69765d962
Removed un-needed file
2017-11-22 16:24:16 +00:00
Richard Davey
1067432174
Modified Matter source to add ignoreGravity option as it can't be monkey-patched in
2017-11-22 16:24:09 +00:00
Richard Davey
8add2510ac
Added Factory constraint functions
2017-11-22 16:23:47 +00:00
Richard Davey
f62409d83b
Matter objects now have a reference to the world in which they were added
2017-11-22 14:13:25 +00:00
Richard Davey
f88732cbb7
Added Sleep Start and Sleep End events
2017-11-22 14:13:10 +00:00
Richard Davey
d5a7579f26
Added new Sleep component
2017-11-22 14:12:57 +00:00
Richard Davey
b969dee104
Merge branch 'master' of https://github.com/photonstorm/phaser
2017-11-22 02:25:44 +00:00
Richard Davey
1e399310b3
Added Stack to the Factory
2017-11-22 02:25:42 +00:00
Richard Davey
0543486d16
Added Matter collision events
2017-11-22 02:25:30 +00:00
Richard Davey
7609eb3131
Added new Matter Collision component
2017-11-22 02:25:06 +00:00
Michael Hadley
0fd6779107
Adding a couple notes about methods that manipulate multiple tiles
2017-11-21 19:19:13 -06:00
Michael Hadley
e19de28932
Tilemap & layers now recalc faces (with a parameter for disabling recalc)
2017-11-21 19:18:34 -06:00
Michael Hadley
bdea565586
Better optimized calc/recalc faces methods for tiles
...
These eliminate the need for the preventRecalc method from v2. If an individual tile is changed with putTileAt, only the min number of faces will be recalculated (vs all faces being recalculated in v2)
2017-11-21 19:16:46 -06:00
Michael Hadley
dd8bbfa625
Update SetCollision methods to track which indices have been set to collide
2017-11-21 19:13:43 -06:00
Michael Hadley
e3dbf7c2d0
Fixing internal method name typos
2017-11-21 19:07:22 -06:00
Felipe Alfonso
500da5d07f
Canvas GeometryMask rendering
2017-11-21 20:21:43 -03:00
Pavle Goloskokovic
cd43f0095c
fixed deprecation issues with AudioParam for WebAudioSoundManager
2017-11-21 19:47:43 +01:00
Pavle Goloskokovic
1f32f04036
fixed deprecation issues with AudioParam for WebAudioSound
2017-11-21 19:47:27 +01:00
Pavle Goloskokovic
658e8c0ee6
implemented onBlur and onFocus methods for WebAudioSoundManager
2017-11-21 18:09:30 +01:00
Pavle Goloskokovic
ab9a9c951f
bound onBlur and onFocus methods to corresponding game events
2017-11-21 18:06:18 +01:00
Pavle Goloskokovic
dd824c4a79
added onBlur and onFocus methods to BaseSoundManager
2017-11-21 18:04:54 +01:00
Pavle Goloskokovic
0e04036d1f
Merge remote-tracking branch 'origin/master'
2017-11-21 18:02:35 +01:00
Pavle Goloskokovic
f00421f112
changed muteOnPause flag to be pauseOnBlur for BaseSoundManager
2017-11-21 18:02:24 +01:00
Richard Davey
97e55b6aa2
Removed un-needed file.
2017-11-21 16:55:10 +00:00
Richard Davey
3a96caf2f6
Updated the entry point.
2017-11-21 16:55:02 +00:00
Richard Davey
46dc75f06b
New Matter World system, with new setBounds, setGravity, add, create and other helpers.
2017-11-21 16:54:54 +00:00
Richard Davey
4f00477f59
MatterImage and MatterSprite allow you to easily create Game Objects with embedded Matter physics bodies.
2017-11-21 16:54:20 +00:00
Richard Davey
32766ca509
New Matter system handler.
2017-11-21 16:53:55 +00:00
Richard Davey
4702ed7400
New components index.
2017-11-21 16:53:44 +00:00
Richard Davey
b9750bec9d
Updated the Factory so it now generates the new MatterImage and MatterSprite objects as well as basic geometry based bodies.
2017-11-21 16:53:36 +00:00
Richard Davey
1442a2605f
A custom module entry point that removes un-needed components.
2017-11-21 16:53:13 +00:00
Richard Davey
dff633cc62
Added the Bounce Matter component for an easier way to set restitution.
2017-11-21 16:52:54 +00:00
Richard Davey
2e11c18470
Added the Force Matter component including applyForce, forceFrom for a world position and thrust, thrustLeft, thrustRight and thrustBack.
2017-11-21 16:52:39 +00:00
Richard Davey
d8d9eb19c8
Added the Friction Matter component to set the static, air and normal friction a body receives.
2017-11-21 16:52:14 +00:00
Richard Davey
93d246e948
Added the Mass Matter component to set the mass and density of a body.
2017-11-21 16:51:54 +00:00
Richard Davey
a5e8d1e2d7
Added the Sensor Matter component.
2017-11-21 16:51:41 +00:00
Richard Davey
4a89ffa881
Added the Static Matter component to set a body as static if you don't specify it in the options config.
2017-11-21 16:51:33 +00:00
Richard Davey
d79e4a6e0c
Added the Transform Matter component allowing for body scaling and rotation feedback direct from and to the Body.
2017-11-21 16:51:14 +00:00
Richard Davey
12e43c315e
Added the Velocity Matter component
2017-11-21 16:50:56 +00:00
Pavle Goloskokovic
526df860d9
added method for unlocking audio context on mobile devices
2017-11-21 15:43:10 +01:00
Pavle Goloskokovic
6f79ba11e1
Merge remote-tracking branch 'origin/master'
2017-11-21 15:23:32 +01:00
Michael Hadley
105dc755ce
Tilemap & layers: optimized SetCollision methods
...
v2 was structured in a way where a full pass through ALL tiles would occur if SetCollisionBetween or SetCollisionByExclusion was used. That's a huge penalty for large tilemaps, so this version duplicates some loop code for the sake of speed.
2017-11-20 20:08:50 -06:00
Richard Davey
213b7b4a86
Refactoring matter.js include
2017-11-21 02:04:05 +00:00
Richard Davey
fb83d6dab5
Starting merge of Matter JS.
2017-11-20 16:54:26 +00:00
Pavle Goloskokovic
cafa91005f
updated description for detune setting and added a check to see if it's available, webkit implementation does not support it
2017-11-20 14:54:33 +01:00
Richard Davey
d20b7abba6
Beta 11 tag.
2017-11-20 11:16:52 +00:00
Michael Hadley
21584f922c
Fix for last commit
2017-11-18 16:11:51 -06:00
Michael Hadley
3f14382951
Make naming consistent for accessing individual tiles (e.g. getTile vs getTileAt)
2017-11-18 15:41:26 -06:00
Michael Hadley
759252a078
Better handling of resizing a tilemap
...
Force the tilesets and tiles to inherit their tile size from the tilemap
2017-11-18 15:40:27 -06:00
Michael Hadley
e2960486a9
Filling out Tile with some methods & props from v2
2017-11-18 15:38:46 -06:00
Michael Hadley
b48d82daee
Format name typo
2017-11-18 08:41:57 -06:00
Michael Hadley
d2f72fbe58
Create CullTiles component to allow static and dynamic layers to cull when needed
...
Fixes performance issue with canvas static tile renderer on large maps
2017-11-18 08:31:59 -06:00
Michael Hadley
b5fb0b8879
Refactor in order to update TilemapCreator & TilemapFactory
2017-11-17 15:55:12 -06:00
Michael Hadley
f82217e868
Move Parse to tilemap/Parse
2017-11-17 15:54:18 -06:00
Michael Hadley
49854bfd1b
Format Typo
2017-11-17 15:49:32 -06:00
Michael Hadley
6da642bd99
Set alpha in dynamic layer canvas renderer
...
Set it directly because of the explicit save/restore commands throw the renderer's internal alpha out-of-sync
2017-11-17 15:31:41 -06:00
Felipe Alfonso
320c0902f6
Small fixes with texture binding to MaskRenderer and WebGLRenderer.
2017-11-17 18:01:06 -03:00
Michael Hadley
5535af2a17
Bug fix: tilemap layer renderer didn't account for layer xy position
2017-11-17 13:53:11 -06:00
Michael Hadley
09ed883f4d
Remove old todos in static layer
2017-11-17 13:52:32 -06:00
Michael Hadley
b8e8d9d3aa
Made data structure for maps and layers more explicit via classes & default props
2017-11-17 13:16:39 -06:00
Richard Davey
7a2b970bb1
Added SetTint (and Shuffle into the index)
2017-11-17 18:29:51 +00:00
Richard Davey
5f1c022866
lint fix
2017-11-17 18:29:50 +00:00
Richard Davey
1d68b5feb7
Set the default values in case there is a delay (stops getValue returning wrong value)
2017-11-17 18:29:49 +00:00
Richard Davey
52bb930cdf
Abort if distance is zero.
2017-11-17 18:29:49 +00:00
Pavle Goloskokovic
82083897aa
updated source stopping logic for WebAudioSound class
2017-11-17 18:38:23 +01:00
Pavle Goloskokovic
6897d6567b
updated checks in playback control methods for BaseSound class
2017-11-17 18:37:49 +01:00
Pavle Goloskokovic
8aafefa6c2
Merge remote-tracking branch 'origin/master'
2017-11-17 17:34:21 +01:00
Pavle Goloskokovic
6577a232a1
adding flag to WebAudioSoundManager indicating if Web Audio implementation is webkit or standards based
2017-11-17 17:30:29 +01:00
Pavle Goloskokovic
9098b806b2
added checks to playback control methods for WebAudioSound
2017-11-17 17:17:06 +01:00
Pavle Goloskokovic
40c4b9f6e5
added checks to playback control methods for BaseSound class
2017-11-17 17:16:06 +01:00
Pavle Goloskokovic
720d2a9665
moved source buffer stopping and removing to separate method for reuse
2017-11-17 17:07:04 +01:00
Pavle Goloskokovic
a6fcb4cf53
added a couple of TODOs
2017-11-17 17:02:11 +01:00
Pavle Goloskokovic
478656df98
moved source buffer creation and starting to separate method for reuse
2017-11-17 17:01:12 +01:00
Richard Davey
fd4f08e4a7
Updated to latest release of matter-js.
2017-11-17 15:29:37 +00:00
Richard Davey
56249c8272
Merge pull request #3091 from Twilrom/bugfixes
...
Bugfixes
2017-11-17 15:23:27 +00:00
Pavle Goloskokovic
e6f17744b6
handling source buffer on method calls for WebAudioSound
2017-11-17 16:16:01 +01:00
Pavle Goloskokovic
7b90fc7f90
updating pausedTime value on method calls for WebAudioSound
2017-11-17 15:42:22 +01:00
Pavle Goloskokovic
f7f5bebd72
added pausedTime field to WebAudioSound class
2017-11-17 15:33:42 +01:00
Pavle Goloskokovic
f1a15571ff
setting startTime to context current time on play for WebAudioSound
2017-11-17 15:29:49 +01:00
Pavle Goloskokovic
7f0930eec0
stopping source buffer if sound is already playing on play for WebAudioSound
2017-11-17 15:28:27 +01:00
Pavle Goloskokovic
ead02ec186
added super calls to pause and resume methods for WebAudioSound
2017-11-17 15:23:52 +01:00
Pavle Goloskokovic
d1fcc39fd3
setting playback flags to correct values on resume call for BaseSound
2017-11-17 15:18:51 +01:00
Pavle Goloskokovic
1d7d488e68
setting playback flags to correct values on pause call for BaseSound
2017-11-17 15:16:25 +01:00
Pavle Goloskokovic
c5436c7fcc
setting playback flags to correct values on play call for BaseSound
2017-11-17 15:14:57 +01:00
Pavle Goloskokovic
a9692ce2dd
stopping source and resetting fields on stop call for WebAudioSound
2017-11-17 15:05:17 +01:00
Pavle Goloskokovic
38a8ce378d
resetting flags on stop call for BaseSound
2017-11-17 15:03:59 +01:00
Michael Hadley
3266974ea0
Tilemap & layer WorldXY methods: get, has, put, remove
2017-11-17 07:58:33 -06:00
Pavle Goloskokovic
0d1fb8a15e
added startTime field to WebAudioSound class
2017-11-17 14:57:57 +01:00
Pavle Goloskokovic
7a4939d435
added isPaused field to BaseSound class
2017-11-17 14:51:23 +01:00
Richard Davey
ea989edca1
GameObjectCreator is now bootable and maintains its own display and update list references.
2017-11-17 13:30:53 +00:00
Richard Davey
6ccae5ec49
Particle Manager no longer uses BuildGameObject and instead manages its own addition to the system lists.
2017-11-17 13:30:29 +00:00
Richard Davey
d74018f3d0
Rogue null
check borked the creation of emitters when a null frame was specified.
2017-11-17 13:30:07 +00:00
Richard Davey
153d1a113a
Fixed factory name.
2017-11-17 13:29:33 +00:00
Richard Davey
f29d94356c
eslint tidy
2017-11-17 13:29:23 +00:00
Pavle Goloskokovic
0eca17520c
updated references in sound folder index.js
2017-11-17 14:18:22 +01:00
Pavle Goloskokovic
3828540ba4
moved web audio implementations into separate folder
2017-11-17 14:17:59 +01:00
Michael Hadley
b34d18e10c
World to Tile conversion on maps and layers - both accounting for camera scroll
2017-11-16 20:36:45 -06:00
Michael Hadley
205675c387
Tilemap: prevent methods from acting on a static tilemap layer & warn user
2017-11-16 19:58:35 -06:00
Michael Hadley
b34f8a9dcc
Associate tilemap layer data with the static or dynamic tilemap layer that "owns" it
...
This enforces 1x tilemap layer data <-> 1x static/dynamic tilemap layer and allows the Tilemap instance to look up the static/dynamic tilemap layer when needed.
2017-11-16 19:55:17 -06:00
Michael Hadley
83b7df2a73
Tilemap: destroy, removeAllLayers, setTileSize
2017-11-16 19:09:28 -06:00
Michael Hadley
63fb2e863f
Tilemap & layer: ReplaceByIndex, FindByIndex, SwapByIndex
2017-11-16 19:08:58 -06:00
Michael Hadley
4c306d60a7
Last Tileset API method to match v2
2017-11-16 15:25:45 -06:00
Michael Hadley
e6c6d1ddce
TIlemap & layers: GetTileAtWorldXY
2017-11-16 13:27:52 -06:00
Michael Hadley
c2268f3dee
PutTile, RemoveTile & Tile#Copy
2017-11-16 13:09:07 -06:00
Michael Hadley
2b08daff32
Tilemap: modularize empty map generators & add createBlankDynamicLayer
2017-11-16 11:44:24 -06:00
Pavle Goloskokovic
a62d8a0174
Merge remote-tracking branch 'origin/master'
2017-11-16 17:48:12 +01:00
Richard Davey
a60562a634
'add' shouldn't control the update state.
2017-11-16 16:47:13 +00:00
Pavle Goloskokovic
52e1cdf823
Merge remote-tracking branch 'origin/master'
2017-11-16 17:27:24 +01:00
Pavle Goloskokovic
f318aa7450
defined detune property on WebAudioSound prototype
2017-11-16 17:25:06 +01:00
Pavle Goloskokovic
e456ee716b
defined detune property on WebAudioSoundManager prototype
2017-11-16 17:24:20 +01:00
Pavle Goloskokovic
7d7d8a7c75
added _rate field to actually hold that value to WebAudioSoundManager
2017-11-16 17:23:26 +01:00