Skip to content

Commit f2491f3

Browse files
committed
Clean up.
1 parent 045c3bd commit f2491f3

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

src/extras/objects/MorphBlendMesh.js

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -299,11 +299,15 @@ THREE.MorphBlendMesh.prototype.update = function ( delta ) {
299299

300300
if ( animation.directionBackwards ) mix = 1 - mix;
301301

302-
if (animation.currentFrame !== animation.lastFrame) {
303-
this.morphTargetInfluences[animation.currentFrame] = mix * weight;
304-
this.morphTargetInfluences[animation.lastFrame] = ( 1 - mix ) * weight;
302+
if ( animation.currentFrame !== animation.lastFrame ) {
303+
304+
this.morphTargetInfluences[ animation.currentFrame ] = mix * weight;
305+
this.morphTargetInfluences[ animation.lastFrame ] = ( 1 - mix ) * weight;
306+
305307
} else {
306-
this.morphTargetInfluences[animation.currentFrame] = weight;
308+
309+
this.morphTargetInfluences[ animation.currentFrame ] = weight;
310+
307311
}
308312

309313
}

0 commit comments

Comments
 (0)