4ian / GDevelop

🎮 Open-source, cross-platform 2D/3D/multiplayer game engine designed for everyone.
https://gdevelop.io
Other
10.84k stars 850 forks source link

Crash while using an editor #4128

Closed japp-ctapuk closed 2 years ago

japp-ctapuk commented 2 years ago

=> Please write here a short description of when the error occured and how to reproduce it. You also may have to create an account on GitHub before posting.

When you're ready, click on "Submit new issue". Don't change the rest of the message. Thanks!

Error stack (don't write anything here)

TypeError: Cannot read properties of null (reading 'TileMapManager')
    at l.updateTileMap (https://editor.gdevelop.io/static/js/66.c50f9325.chunk.js:2:343574)
    at new l (https://editor.gdevelop.io/static/js/66.c50f9325.chunk.js:2:342590)
    at Object.createNewInstanceRenderer (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:58969)
    at e.getRendererOfInstance (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:1160057)
    at instancesRenderer.invoke (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:1161880)
    at 3052 (https://editor.gdevelop.io/libGD.js?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:9:17964)
    at _emscripten_asm_const_iii (https://editor.gdevelop.io/libGD.js?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:9:28312)
    at https://editor.gdevelop.io/libGD.wasm?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:wasm-function[1603]:0x3c8dd
    at https://editor.gdevelop.io/libGD.wasm?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:wasm-function[59]:0x1ffe0
    at https://editor.gdevelop.io/libGD.wasm?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:wasm-function[2695]:0x8236c
    at https://editor.gdevelop.io/libGD.wasm?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:wasm-function[696]:0x2b38d
    at Module._emscripten_bind_InitialInstancesContainer_IterateOverInstancesWithZOrdering_2 (https://editor.gdevelop.io/libGD.js?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:9:356587)
    at InitialInstancesContainer.IterateOverInstancesWithZOrdering.InitialInstancesContainer.IterateOverInstancesWithZOrdering [as iterateOverInstancesWithZOrdering] (https://editor.gdevelop.io/libGD.js?cache-buster=5.0.139-99b615c573974f019e2218e6de2dd5e7f50e0727:9:1063560)
    at e.value (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:1163767)
    at e.value (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:612186)
    at e._renderScene (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:639696)
    at n.value (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:643848)
    at n.value (https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:640248)
    at cs (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:419634)
    at wu (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:437344)
    at t.unstable_runWithPriority (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:456644)
    at $i (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:381126)
    at _u (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:434007)
    at su (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:430138)
    at https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:381417
    at t.unstable_runWithPriority (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:456644)
    at $i (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:381126)
    at Qi (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:381362)
    at Ji (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:381297)
    at nu (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:426721)
    at ba (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:398512)
    at https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:1277300
    at new Promise (<anonymous>)
    at https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:1277263
    at https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:370608
    at https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:373589
    at https://editor.gdevelop.io/static/js/1.371c6ce5.chunk.js:1:378856
    at l (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:458531)
    at Generator._invoke (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:458319)
    at Generator.next (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:458956)
    at r (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:419)
    at s (https://editor.gdevelop.io/static/js/64.c567af61.chunk.js:2:630)

Component stack (don't write anything here)


    in n
    in div
    in div
    in Unknown
    in Measure
    in i
    in o
    in n
    in div
    in div
    in t
    in div
    in t
    in Unknown
    in n
    in c
    in div
    in n
    in n
    in t
    in Unknown
    in Unknown
    in div
    in n
    in Unknown
    in div
    in Unknown
    in n
    in d
    in j
    in f
    in j
    in h
    in g
    in c
    in n
    in t
    in be
    in n
    in Unknown
    in g
    in t
    in l
    in o
    in n
    in n
    in DragDropContext(n)
    in n
    in c

Other details

D8H commented 2 years ago

The crash happens at this line because the TilemapHelper dependency is not linked. https://github.com/4ian/GDevelop/blob/55cc75e990ea7c3ffa646d5af34b82fb4c7cd365/Extensions/TileMap/JsExtension.js#L869

The dependency is declared here: https://github.com/4ian/GDevelop/blob/55cc75e990ea7c3ffa646d5af34b82fb4c7cd365/Extensions/TileMap/JsExtension.js#L762-L765

The attribute name is not set correctly https://github.com/4ian/GDevelop/blob/55cc75e990ea7c3ffa646d5af34b82fb4c7cd365/newIDE/app/src/JsExtensionsLoader/BrowserJsExtensionsLoader.js#L107-L118

The issue happened on the web-app.

Unable to load module "helper/TileMapHelper". Are you sure you registered it using ObjectsRenderingService.registerModule? This is mandatory for the web-app to have the file bundled.