# Node Materials not compiling in 4.2.beta14

**URL:** <https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089>\
**Category:** Bugs\
**Created:** [October 21, 2020, 2:03pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089 "2020-10-21T14:03:32Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![dennemark](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/dennemark/32/10745_2.png) [@dennemark](https://forum.babylonjs.com/u/dennemark)\
**Post date:** [October 21, 2020, 2:03pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089/1 "2020-10-21T14:03:32Z")

</div>

Hi,  
I have updated to the latest preview version of babylonjs, since it contains some updates to CSM that I wanted to try out.  
But currently I am not able to get my app to work, since node materials are not compiling correctly. Strangely, I can easily load them through [nme.babylonjs.com](http://nme.babylonjs.com) as well as playground. But when I start my app, it says:

`Uncaught (in promise) TypeError: block is undefined`  
and points to this line of code: [Babylon.js/nodeMaterial.ts at 3b397b7cc910917fdedfaf413b9a44afd7a59b4c · BabylonJS/Babylon.js · GitHub](https://github.com/BabylonJS/Babylon.js/blob/3b397b7cc910917fdedfaf413b9a44afd7a59b4c/src/Materials/Node/nodeMaterial.ts#L1769)

When I create a new nme material, it also complains and the resulting material in the nme is empty:

`Uncaught TypeError: Cannot read property 'World' of undefined`

> <https://github.com/BabylonJS/Babylon.js/blob/3b397b7cc910917fdedfaf413b9a44afd7a59b4c/src/Materials/Node/nodeMaterial.ts#L1401>

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [October 21, 2020, 3:10pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089/2 "2020-10-21T15:10:11Z")

</div>

@dennemark are there any simple ways for us to repro ???

@Evgeni_Popov would you wind having a quick look ?

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [October 21, 2020, 3:22pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089/3 "2020-10-21T15:22:54Z")

</div>

I could protect it but not sure it is the right approach here what do you think ?

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [October 21, 2020, 3:30pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089/4 "2020-10-21T15:30:12Z")

</div>

Are you using PBR blocks in your node material?

There has been some breaking changes lately due to PBR (re)design…

---

<div class="post-metadata">

**Author:** ![dennemark](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/dennemark/32/10745_2.png) [@dennemark](https://forum.babylonjs.com/u/dennemark)\
**Post date:** [October 21, 2020, 3:31pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089/5 "2020-10-21T15:31:58Z")

</div>

Hey! I guess this must be it! I will try to research it! Just realised that the online nme version now is running beta14, too. I think earlier today it was 13, if I am not mistaken. Now my material is complaining, too, in the online nme.

---

<div class="post-metadata">

**Author:** ![dennemark](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/dennemark/32/10745_2.png) [@dennemark](https://forum.babylonjs.com/u/dennemark)\
**Post date:** [October 21, 2020, 4:00pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089/6 "2020-10-21T16:00:57Z")

</div>

Update: Yes, the new PBR node was the issue. I think it is mostly, because the reflectivity node is not existent anymore. So a workaround is currently, to find the reflectivity and pbr block inside of the json and delete them as well as their position. Afterwards place a new pbr material inside and connect the missing links.

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [October 21, 2020, 4:24pm UTC](https://forum.babylonjs.com/t/node-materials-not-compiling-in-4-2-beta14/15089/7 "2020-10-21T16:24:29Z")

</div>

Yes, sorry for this, we simplified the PBR blocks quite a bit and we think it’s clearer now but it’s a breaking change for some people (we still did it because it’s a new feature in 4.2 and 4.2 is not released yet).
