url
http://avatarfashionpr.awardspace.com/rekasphotos.html
Hi there,
I’m pretty new to 3d in flash, and I’m working with a kirupa tutorial in the ‘working with 3D in Flash’ section, specifically, the 3d Spinning Menu. The issue I’m having is getting the Menu to display more than one Pane. I’ve created multiple movieclips to house the buttons for various photos, but the actionscript ignores all but the first movieclip. i.e., the menu displays and moves properly, but it only displays one slide (As you can see). What I want to do, obviously, is show all of the thumbnails (not seen, for obvious reasons) in this menu.
Here’s the sourcecode, as it stands:
this.createEmptyMovieClip(“theScene”, 1);
theScene._x = 150;
theScene._y = 100;
objectsInScene = new Array();
focalLength = 500;
spin = 0;
displayPane = function(){
var angle = this.angle + spin;
var x = Math.cos(angle)*this.radius;
var z = Math.sin(angle)*this.radius;
var y = this.y;
var scaleRatio = focalLength/(focalLength + z);
this._x = x * scaleRatio;
this._y = y * scaleRatio;
this._xscale = this._yscale = 100 * scaleRatio;
this._xscale *= Math.sin(angle);
this.swapDepths(Math.round(-z));
};
angleStep = 2Math.PI/8;
for (i=0; i < 8; i++){
attachedObj = theScene.attachMovie(“pane”, “pane”+i, i);
attachedObj.angle = angleStep * i;
attachedObj.radius = 100;
attachedObj.x = Math.cos(attachedObj.angle) * attachedObj.radius;
attachedObj.z = Math.sin(attachedObj.angle) * attachedObj.radius;
attachedObj.y = 40;
attachedObj.display = displayPane;
objectsInScene.push(attachedObj);
}
panCamera = function(){
spin -= this._xmouse/1000;
for (var i=0; i < objectsInScene.length; i++){
objectsInScene.display();
}
};
theScene.onEnterFrame = panCamera;
the version above is pretty unmodified from the kirupa source file (in fact, the source code above is cut and pasted from the tutorial. I had been working with the code and toying with the values and had it pretty decked out for the site, but when I got stuck on the display function, I made one too many modicfications and had to start over…