ciao a tutti...
guardate questa prova...
www.mclab.it/lab.htm
nel mc che corrisponde all'occhio ho inserito il seguente codice
onClipEvent (load) {
x = this._x;
dx = x + 5;
sx = x - 5;
}
onClipEvent (enterFrame) {
if (this._x < dx and _xmouse > x) {
this._x = this._x + 1;
this._xscale = (100 - (this._x - sx));
}
if (this._x > sx and _xmouse < x) {
this._x = this._x - 1;
this._xscale = 100 - (dx - this._x);
}
if (_xmouse == x) {
this._x = this._x;
this._xscale = 100;
}
}
L'effetto è più o meno che volevo, ma ancora non ci siamo...
come posso migliorarlo secondo voi?
obiettivo: i movimenti dell'occhio dovrebbero seguire il mouse