[AS2] Adding to the dynamic 3d carousel // GotoAndPlay.com

Hey all, i just ran through the ‘3d carousel’ tutorial at gotoAndPlay.com, all was good but I got a little stumped in a few things i would like to do/add.

here are a few things i would like to add to this code below:

  • Different colour panel containers, so somehow i would need to edit the attachMovie with a tint on the mc or maybe load in a another mc?
  • Each mc to be clickable.
  • A unique link for each items
  • The rotating animation to only occur when the mouse is in actual flash movie, so once out of the active area the rotation from the mouse x position to stop.

Also i was aware that GotoAndPlay tutorials have a xml version of the tutorial that can import links/images/ descriptions but for this particular task i cannot have any external files, so it’s all got to be within this one file.

any help will be appreciated. :slight_smile:

here is the code:

var numOfItems:Number = 3;
var radiusX:Number = 80;
var radiusY:Number = 40;
var centerX:Number = Stage.width/2;
var centerY:Number = Stage.height/2;
var speed:Number = 0.05;

for(var i=0; i<numOfItems; i++)
 var t = this.attachMovie("item", "item"+i, i+1);
 t.Angle = i * ((Math.PI*2)/numOfItems);
 t.onEnterFrame = mover;

function mover()
    this._x     = Math.cos(this.Angle) * radiusX + centerX;
    this._y     = Math.sin(this.Angle) * radiusY + centerY;
    var s:Number = this._y/ (centerY+radiusY);
    this._xscale = this._yscale = s *100;
    this.Angle += this._parent.speed; 
    this.swapDepths(Math.round(this._xscale) + 100);
    this.onRelease = released;

released = function()
    trace("im hit!!");
    /////////////would like to generate a link for each panel //eg. this.getURL("something.html","_blank");

this.onMouseMove = function()
    speed = (this._xmouse - centerX)/2000;