Hi all, I’m basically new to Playcanvas, I’m trying to replicate the custom shader tutorial but with the chunk system. I was able to make the opacity part. But I have a problem with the emission part. For some reason, the map does not animate as you can see here Dissolve Shader - PLAYCANVAS
The emissivePS is correctly replaced because if I try to use the original chunk from Github it works like a charm. I’ve made the changes by following this shader in Unity DISSOLVE using Unity Shader Graph - YouTube
This is the emissive chunk. The opacity one is similar and it works
The #ifdef conditionals are there to make the default chunk be applicable to many diffferent scenarios and use cases. When the engine generates the final shader for a material, it branches out and composes a final shader text based on how the chunk is used in the given material.
SInce you are overriding it, you know exactly what you need and what you don’t in your chunk. For example, you are not trying to modify a vertex color, so you don’t actually need that conditional there (unless you do, since I didn’t look into that tutorial). In fact you don’t need any of them, and can simplify it, like:
I was trying to publish to let you see the result, but for some reason when you open the published link it gives me this error “Failed to load resource: net::ERR_BLOCKED_BY_CLIENT” in console.