3D Zoom Menu
Posted On: July 28, 2009
Price: Free!
Flash Player Version: 8
Swishmax Version: Swishmax2, 2008.08.12
Comments: 6 comments
Price: Free!
Flash Player Version: 8
Swishmax Version: Swishmax2, 2008.08.12
Comments: 6 comments
Click on items to view them zooming in a 3D field.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 | onFrame (1) { var numItems = 10; var focalLength = 100; var centerX = Stage.width/2; var centerY = Stage.height/2; this.initCamera = function(){ this.oCamera = new Object(); this.oCamera.x = 0; this.oCamera.y = 0; this.oCamera.z = focalLength/2; this.oCamera.dx = 0; this.oCamera.dy = 0; this.oCamera.dz =-focalLength/2; this.oCamera.s = 90; this.oCamera.t = 0; this.onEnterFrame = function(){ with(this.oCamera){ t = (t>=50) ? null : t+1; x = (t>=50) ? x : easeIn(t,x,(dx-x),50); y = (t>=50) ? y : easeIn(t,y,(dy-y),50); z = (t>=50) ? z : easeIn(t,z,(dz-z),50); } } this.btn.onRelease = function(){ this._parent.oCamera.dx = 0; this._parent.oCamera.dy = 0; this._parent.oCamera.dz = -focalLength/2; this._parent.oCamera.t = 0; } for(var i = 0; i<=numItems;i++){ this.attachMovie("instance", "instance_mc_"+i,i); clip = this["instance_mc_"+i]; clip.x = random(Stage.width)- centerX ; clip.y = random(Stage.height)- centerY; clip.z = random(focalLength*2)-focalLength; clip.ID.text = i; clip.onPress = function(){ this.swapDepths(numItems+1); this._parent.oCamera.t = 0; this._parent.oCamera.dx = this.x; this._parent.oCamera.dy = this.y; this._parent.oCamera.dz = this.z+this._parent.focalLength*.9; } clip.onEnterFrame = function(){ var zpos = (this.z-this._parent.oCamera.z); var scale = this._parent.focalLength/(this._parent.focalLength + zpos); this._visible = (scale <= 10); this._x = (this.x - this._parent.oCamera.x )*scale + centerX; this._y = (this.y - this._parent.oCamera.y )*scale + centerY; this._xscale = scale*100; this._yscale = scale*100; this._alpha = scale*100; } } } this.rand = function(nb1,nb2){ return Math.floor(Math.random() * ((nb2 - nb1)+ 1)) + nb1; } this.easeIn = function (t, b, c, d,a,p) { if (t==0) return b; if (t==d) return b+c; if ((t/=d/2) <= 1) return c/2 * Math.pow(2, 10 * (t - 1)) + b; return c/2 * (-Math.pow(2, -10 * --t) + 2) + b; }; initCamera(); stop(); } |



I downloaded this and it made me realize how dumb I am… it works great, but I don’t understand how to use it really… I mean, I know how I would like to use it… but the code and having the buttons actually display something when it zooms in… like a scroller… or text and a pic… something like that… if you can do something like that, email me the price on that… or if I haven’t made it clear enough.
Obrigado!
Yes i see the same problem.. i found the sticky buttoms very editable.. but this 3d i cant seem to figure out how to use at all !?
whats the secret !? ;O)
Cool site btw.. iiiii like it alot..
Use your imagination! =)
belive me i tryed.. i dont get scripting.. im a visual kind of guy..
i dont know how to make the numbers into f.ex menu text.. when i change one ball, they all change. i knwo its to do with the ID.. but i cant figure out how to edit it.
If you want to add different names for each ball, you’ll need to make an array and apply the names like:
this.attachMovie(”instance”, “instance_mc_”+i,i);
clip = this["instance_mc_"+i];
clip.ID.text = yourCreatedArray{i}.toString();
ok.. i give up.. nice thing though.. would have been a cool Component