From e7db14526cd90b9b4d2843e6f40b75ceb4965a03 Mon Sep 17 00:00:00 2001 From: boytchev <70705048+boytchev@users.noreply.github.com> Date: Sun, 6 Oct 2024 16:53:08 +0300 Subject: [PATCH] Eslinted --- docs/example-posture-blend-2.html | 9 +++++---- src/shapes/LimbShape.js | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/docs/example-posture-blend-2.html b/docs/example-posture-blend-2.html index 274161d..b9a7a23 100644 --- a/docs/example-posture-blend-2.html +++ b/docs/example-posture-blend-2.html @@ -49,11 +49,12 @@ man1.position.x = 1; man1.stepOnGround(); - function transparentMaterial( material ) - { + function transparentMaterial( material ) { + material.transparent = true; material.opacity = 0.3; material.depthWrite = false; + } @@ -61,8 +62,8 @@ if ( object.material ) { - if( Array.isArray( object.material ) ) - for( var mat of object.material ) transparentMaterial( mat ); + if ( Array.isArray( object.material ) ) + for ( var mat of object.material ) transparentMaterial( mat ); else transparentMaterial( object.material ); diff --git a/src/shapes/LimbShape.js b/src/shapes/LimbShape.js index daff902..28bcba9 100644 --- a/src/shapes/LimbShape.js +++ b/src/shapes/LimbShape.js @@ -18,7 +18,7 @@ class LimbShape extends ParametricShape { offset = params[ 5 ], scale = params[ 6 ], rad = params[ 7 ]; - + super( null, BODY_COLORS.LIMBS, function ( u, v, target ) { u = THREE.MathUtils.smoothstep( u, 0, 1 );