Hi,
That was an intentional change. App.materials was deprecated because it was buggy and didn’t properly track all scene changes, like adding or removing materials. Also, that property wasn’t documented or recommended for use anyway.
The code that you can see in the 3.4 version is just some backward compatibility measure for old puzzles logic scripts.
If this difference is your intention, I wonder how I can get materials list of ver.3.3. or 3.4. If this is a bug, I hope it will be fixed for the next version.
You can get the list of the materials currently used on the scene like this:
var materials = [];
app.scene.traverse(function(obj) {
if (obj.material && materials.indexOf(obj.material) === -1) {
materials.push(obj.material);
}
});
Co-founder and lead developer at Soft8Soft.