Kaynağa Gözat

MD2CharacterComplex: fix frontDeceleration attribute name (#30817)

Co-authored-by: Samuel Rigaud <rigaud@gmail.com>
Samuel Rigaud 1 yıl önce
ebeveyn
işleme
f06cc7d42b
1 değiştirilmiş dosya ile 3 ekleme ve 3 silme
  1. 3 3
      examples/jsm/misc/MD2CharacterComplex.js

+ 3 - 3
examples/jsm/misc/MD2CharacterComplex.js

@@ -78,12 +78,12 @@ class MD2CharacterComplex {
 		this.backAcceleration = 600;
 
 		/**
-		 * The character's front decceleration.
+		 * The character's front deceleration.
 		 *
 		 * @type {number}
 		 * @default 600
 		 */
-		this.frontDecceleration = 600;
+		this.frontDeceleration = 600;
 
 		/**
 		 * The character's angular speed.
@@ -684,7 +684,7 @@ class MD2CharacterComplex {
 			if ( this.speed > 0 ) {
 
 				const k = exponentialEaseOut( this.speed / this.maxSpeed );
-				this.speed = MathUtils.clamp( this.speed - k * delta * this.frontDecceleration, 0, this.maxSpeed );
+				this.speed = MathUtils.clamp( this.speed - k * delta * this.frontDeceleration, 0, this.maxSpeed );
 
 			} else {
 

粤ICP备19079148号