Glow Effect while Mouseover
Hello,
I am struggling with creating an effect on an object. It is supposed to glow while the mouse is hovering over it. Below is the code I was able to produce, but it is not properly working and I am running out of ideas (as well as google results to this issue) what the remedy to the problem is.
stage.enableMouseOver(30);
var _this = this;
this.bug.addEventListener('mouseover', function(){
var glow = new createjs.Shadow("rgba(255,0,0,1)", 0, 10, 20);
_this.bug.shadow = [glow];
_this.bug.cache(0,0,222,248);
});
this.bug.addEventListener('mouseout', function(){
var glow = new createjs.Shadow("rgba(0,0,0,1)", 1, 0, 1);
_this.bug.shadow = [glow];
_this.bug.cache(0,0,222,248);
});
Thank you for any help in advance.
