Hi,
i am using senoculars ParticleBehavior class to get ‘leaves’ to repel from the mouse, and can’t seem to get it to work.
here is what i have:
[AS]
import com.senocular.ParticleBehavior;
//------------------------------------------------------------------------------------
xp = 10;
yp = 10;
xpo = 10;
ypo = 10;
sp = 20;
xGrid = (Math.ceil(Stage.width/20));
yGrid = (Math.ceil(Stage.height/20));
xgm = 1;
points = xGrid*yGrid;
//------------------------------------------------------------------------------------
for (i=1; i<=points; i++) {
//trace(i);
l.attachMovie(“leaf”, “leaf”+i, l.getNextHighestDepth(), {_x:xp, _y:yp});
l[“leaf”+i]._rotation = random(360);
l[“leaf”+i].onEnterFrame=lFrame
xp += sp;
xgm++;
if (xgm>xGrid) {
yp += sp;
xgm = 1;
xp = xpo;
}
}
function lFrame() {
this.repel();
[/AS]
does anyone have any experience with this?
thanks!