Skip to content

Commit

Permalink
Merge pull request #1332 from xiaoguzhu/LayaAir_3.1
Browse files Browse the repository at this point in the history
fix: material lost rendermode after reload
  • Loading branch information
xiaoguzhu authored Jan 31, 2024
2 parents 2cd6948 + 96ab0d0 commit 20411fb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/layaAir/laya/loaders/MaterialLoader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ class MaterialLoader implements IResourceLoader {
obsoluteInst.setShaderName(mat._shader.name);
mat._shaderValues.cloneTo(obsoluteInst._shaderValues);
obsoluteInst.renderQueue = mat.renderQueue;
obsoluteInst.materialRenderMode = mat.materialRenderMode;
obsoluteInst.obsolute = false;
mat.destroy();
return obsoluteInst;
Expand Down

0 comments on commit 20411fb

Please sign in to comment.