-
-
Notifications
You must be signed in to change notification settings - Fork 644
-
-
Notifications
You must be signed in to change notification settings - Fork 644
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't create new canvases for TMX Tile Objects. #595
Milestone
Comments
what should we create then ? and entity with a body and a renderable component ? |
It would need the Texture Atlas work that I mentioned in #591, but then this one could just change from creating a new canvas to instead referencing the original texture and an atlas index. |
#591 depends on this bug getting fixed.
Throws the exception after reloading the maps in the platformer example a few times. |
This one was fixed by #592 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
While debugging some changes in the WebGL Renderer, I found that the Tile Objects used in the platformer (the spikes) each have their own canvas object. This makes caching difficult, and will break the batching logic (#591), because none of them share a texture.
The code that creates the canvas is
me.TMXTileset.getTileImage
:melonJS/src/level/TMXTileset.js
Line 302 in 70caf9c
gid
property:melonJS/src/level/TMXObjectGroup.js
Line 261 in 07c1c83
The text was updated successfully, but these errors were encountered: