repo: janusweb action: commit revision: path_from: revision_from: 72e3b0ba55dac2fce28d42adee6a1b21ff58d670: path_to: revision_to:
commit 72e3b0ba55dac2fce28d42adee6a1b21ff58d670 Author: James BaicoianuDate: Fri Nov 5 16:35:27 2021 -0700 Respect lighting parameter from ghost definition diff --git a/scripts/janusghost.js b/scripts/janusghost.js
--- a/scripts/janusghost.js
+++ b/scripts/janusghost.js
@@ -280,9 +280,10 @@ elation.require(['janusweb.janusbase', 'engine.things.leapmotion'], function() {
lighting: this.lighting,
//cull_face: 'none'
opacity: 0.9999,
- shader_chunk_replace: {
+ renderorder: this.renderorder || 100,
+ shader_chunk_replace: (this.lighting ? {
'color_fragment': 'color_fragment_discard_close',
- },
+ } : {}),
});
} else {
this.body = bodyid;
@@ -636,6 +637,7 @@ elation.require(['janusweb.janusbase', 'engine.things.leapmotion'], function() {
this.bone_head = ghostdef.bone_head;
this.morphtarget_mouth = ghostdef.morphtarget_mouth;
this.morphtarget_eyes = ghostdef.morphtarget_eyes;
+ this.lighting = elation.utils.any(ghostdef.lighting, true);
if (ghostdef.morphtarget_eyes) {
this.blink();
}
-----END OF PAGE-----