Fix options.detectModel not working
This commit is contained in:
parent
07c927952c
commit
0545117c51
|
|
@ -7,7 +7,7 @@ export class SkinViewer {
|
||||||
|
|
||||||
public domElement: HTMLElement;
|
public domElement: HTMLElement;
|
||||||
public animation: Animation;
|
public animation: Animation;
|
||||||
public detectModel: boolean = false;
|
public detectModel: boolean = true;
|
||||||
public animationPaused: boolean = false;
|
public animationPaused: boolean = false;
|
||||||
public animationTime: number = 0;
|
public animationTime: number = 0;
|
||||||
public disposed: boolean = false;
|
public disposed: boolean = false;
|
||||||
|
|
@ -34,10 +34,9 @@ export class SkinViewer {
|
||||||
constructor(options) {
|
constructor(options) {
|
||||||
this.domElement = options.domElement;
|
this.domElement = options.domElement;
|
||||||
this.animation = options.animation || null;
|
this.animation = options.animation || null;
|
||||||
this.detectModel = options.animation !== false; // true by default
|
if (options.detectModel === false) {
|
||||||
this.animationPaused = false;
|
this.detectModel = false;
|
||||||
this.animationTime = 0;
|
}
|
||||||
this.disposed = false;
|
|
||||||
|
|
||||||
// texture
|
// texture
|
||||||
this.skinImg = new Image();
|
this.skinImg = new Image();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue