private var m_intForce:Number = 300;
public function onEnterFrame(evt:Object) : Void
{
// http://www.solidether.com/luminance/examples/barslundRepulsion.html
var xDif:Number = m_mcContainer._parent._xmouse - x;
var yDif:Number = m_mcContainer._parent._ymouse - y;
var distance:Number = Math.sqrt(xDif*xDif+yDif*yDif);
var tempX:Number = x - (m_intForce/distance)*(xDif/distance);
var tempY:Number = y - (m_intForce/distance)*(yDif/distance);
this.x = (m_intStartX - x)/2+tempX;
this.y = (m_intStartY - y)/2+tempY;
}
Well, not much heard from me in a while… busy busy busy ;) But the birth of Macromedia labs has to be shouted out. No tonly because it is a great initiative, but more so because of the public flex 2.0 alpha can be downloaded in the new labs. Go try it out if you can, i know i will….
After all the mind boggling previews of the new graphics enhancements of the upcoming flash player 8, i was wondering if the same could be said about actionscript performance… well it can :) This movie takes about 20% in Flash player 7….. it takes 1% in flash player 8 (beta!). Sigh, gotta love those MM guys.