Update cat.js

This commit is contained in:
James B. Pollack 2015-10-01 18:52:08 -07:00
parent d0e079ee9d
commit 0ce6a305bd

View file

@ -13,7 +13,9 @@
(function() {
var _this;
Cat = function() {
_this=this;
this.meowSound = SoundCache.getSound("https://s3.amazonaws.com/hifi-public/sounds/Animals/cat_meow.wav");
};
@ -29,11 +31,11 @@
},
update: function() {
if (this.injector !== null) {
this.isMeowing = this.injector.isPlaying;
if (_this.injector !== null) {
_this.isMeowing = this.injector.isPlaying;
}
if (this.isMeowing === false) {
this.injector = null;
if (_this.isMeowing === false) {
_this.injector = null;
}
},