Phaser: Light2D for Dynamic Tilemap Layer Not Working in 3.14.0

Created on 2 Oct 2018  路  9Comments  路  Source: photonstorm/phaser

Version

  • Phaser Version: 3.14.0

Description

Phaser fails to load when trying to use the Light2D pipeline with dynamic tilemaps with the following error:

ForwardDiffuseLightPipeline.js:235 Uncaught TypeError: Cannot read property 'dataSource' of undefined
    at ForwardDiffuseLightPipeline.batchTexture (VM218 dev.js:136518)
    at DynamicTilemapLayerWebGLRenderer [as renderWebGL] (VM218 dev.js:162463)
    at WebGLRenderer.render (VM218 dev.js:135491)
    at CameraManager.render (VM218 dev.js:11608)
    at Systems.render (VM218 dev.js:142452)
    at SceneManager.render (VM218 dev.js:139972)
    at Game.step (VM218 dev.js:6720)
    at TimeStep.step (VM218 dev.js:7535)
    at step (VM218 dev.js:25359)

Example Test Code

Can be observed on the phaser labs example:

http://labs.phaser.io/view.html?src=src\game%20objects\lights\dynamic%20tilemap%20layer.js&v=3.14.0

Additional Information

Worked fine on 3.13.0

http://labs.phaser.io/view.html?src=src\game%20objects\lights\dynamic%20tilemap%20layer.js&v=3.13.0


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

Most helpful comment

I really wish people would stop doing this. If an issue isn't listed in the Change Log, or closed, then it hasn't been fixed yet, no matter how many releases have come out in the meantime. The change log is meticulous and details everything, it wouldn't exclude something like this.

All 9 comments

Can confirm, got the same Bug, this happens only on dynamicTilelayers.

addendum: It seems like _normalmaps_ do not work anymore too. Can anyone confirm?

Normal maps and lights are working fine with the exception being dynamic layers.

You are right, it's only dynamic layers.

Still not working in 3.15.0 and 3.15.1, I suggest to keep using 3.13.0 to people who want to use the Light2D Pipeline and Dynamic Layers while the issue isn't fixed.

I really wish people would stop doing this. If an issue isn't listed in the Change Log, or closed, then it hasn't been fixed yet, no matter how many releases have come out in the meantime. The change log is meticulous and details everything, it wouldn't exclude something like this.

Hello!

@photonstorm , can you please raise a priority of this issue? More than half a year lighting a tilemap is not working.

Thank you!

Is there any workaround for this by the community? I would go back to 3.13.0 but there the collision is not working...
Unfortunately this seems to be a showstopper. I would assume that nearly all bigger Phaser projects use dynamic layers and lighting is a must in many projects as well.
@photonstorm is this issue on the roadmap or unprioritized in the backlog?

I don't want to appear rude. I really love this project, I appreciate all you are doing and know all too well that (dev)time is a finite resource in our lives.

Thank you for submitting this issue. We have fixed this and the fix has been pushed to the master branch. It will be part of the next release. If you get time to build and test it for yourself we would appreciate that.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

HDouss picture HDouss  路  3Comments

JoeBerkley picture JoeBerkley  路  3Comments

JarLowrey picture JarLowrey  路  4Comments

sercand picture sercand  路  3Comments

SKEPDIMI picture SKEPDIMI  路  4Comments