Flash CS3 - Flash CS4

Free tutorials and scripts for all.
Actionscript 3.0

distanziamento rotation

This is a discussion on distanziamento rotation within the Actionscript 3.0 avanzato forums, part of the Flash CS3 generale category; salve a tutti chiedo un aiuto grande a tutti voi io dovrei realizzare un cerchio diviso in parti, all' interno ...


Go Back   Forum Flash CS3 Flash CS4 > Flash CS3 e Actionscript 3.0 > Flash CS3 generale > Actionscript 3.0 avanzato

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 10-04-08, 12:04
Junior Member
 
Join Date: Feb 2008
Posts: 19
Rep Power: 0
lorenzz is on a distinguished road
distanziamento rotation

salve a tutti chiedo un aiuto grande a tutti voi

io dovrei realizzare un cerchio diviso in parti, all' interno di ogni spicchio del cerchio ci sono delle anteprimedi immagini, vicino a questo cerchio ci sono delle sezioni

io vorrei che cliccando su una dell sezioni vicino al cerchio mi spariscano gli spicchi riferiti a quella sezione e i restanti spicchi vadano ad occupare però tutto il cerchio, stanziandosi perfettamente l'uno dall' altro, e cosi via per tutti gli altri pulsanti, ovviamente cliccando su un' altra sezione cè la possibilità di far riapparire gli spicchi, e automaticamente stanziare con gli altri.


ho tentato di essere il piu possibile chiaro nella descrizione

attendo un vostro aiuto, io ci sto sbattendo la testa da 3 giorni e non riesco nemmeno a trovare un punto di partenza


ciaoooooooooooooooo
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #2 (permalink)  
Old 10-04-08, 13:07
Junior Member
 
Join Date: Feb 2008
Posts: 19
Rep Power: 0
lorenzz is on a distinguished road
Re: distanziamento rotation

PS:

se fosse possibile, per ora mi basterebbe riuscire a creare un cerchio formato da clip filmati che caricano al loro interno delle immagini tramite un file xml.

mi potete aiutare su come poter fare per disporre circolarmente i clip?

grazzzzz
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #3 (permalink)  
Old 11-04-08, 12:35
jjletho's Avatar
Member
 
Join Date: Nov 2007
Posts: 69
Rep Power: 1
jjletho is on a distinguished road
Send a message via MSN to jjletho
Riferimento: distanziamento rotation

basta che ti trovi le coordinate relative
in pratica crei un mc che conterrà i cerchi con il centro in 0,0

e poi usi una struttura simile per pescare le coordinate
Attached Files
File Type: pdf cerchio.pdf (53.7 KB, 12 views)

__________________
------------------------------------------------------
Marco Salvatori Design
www.marcosalvatori.com
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #4 (permalink)  
Old 12-04-08, 11:38
Junior Member
 
Join Date: Feb 2008
Posts: 19
Rep Power: 0
lorenzz is on a distinguished road
Re: distanziamento rotation

intanto ti ringrazio per la risposta, ma non mi è molto chiaro..........


il mio problema è quello che tramite actionscript, mettiamo di avere 10 clip filmati duplicati sulla scena 1, questi si devono disporre lungo il perimetro del cerchio, se io poi volessi creare un clip nuovo, questo automaticamente mi verrebbe inserito nel cerchio, ovviamente gia spaziato perfettamente con gli altri,

mi puoi dare qualche dritta piu specifica?



grazie mille
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #5 (permalink)  
Old 12-04-08, 13:38
Junior Member
 
Join Date: Feb 2008
Posts: 19
Rep Power: 0
lorenzz is on a distinguished road
Re: distanziamento rotation

questo è lo script che ordina le immagini a cerhio e se ne aggiungo me le spazia giuste



var moviclips:Array = []
var radius = 300
var maxClips = 19
var degreesOffset = 360 / maxClips
var curr_degreesRot = 40
var total_degreesRot = 0
var frame=0;
_x=300
_y=300


function degToRad(d)
{
return d*(Math.PI/180);
}

function positionMovis(movis, angle, radius)
{


if(angle==105)
{

movis.gotoAndStop(frame+1);
frame++;//to get all the 14 movieclips
//trace(frame);
/*the problem is here*/
if(frame==14)//its taking only 1,2,3,4 and 5
{
frame=1;
}
trace(movis._currentframe);
}
//curr_degreesRot += total_degreesRot;
radians = degToRad(angle);
movis._x = Math.sin(radians) * radius;
movis._y = Math.cos(radians) * radius;
}

function setup()
{
for(i=0; i<maxClips; i++)
{
var degrees = (degreesOffset * i);

var movis = this.attachMovie("pics","pics"+i,this.getNextHighe stDepth());

moviclips.push(movis);
//movis.gotoAndStop(i+1)

movis.degreesOffset = degrees;
movis.setting = Math.cos(degToRad(degrees));
//trace(movis.degreesOffset);

movis.radius = radius;
trace("rt"+movis._currentframe);
positionMovis(movis, movis.degreesOffset, radius);

}
}



function rolling()
{
curr_degreesRot += total_degreesRot;

for(i = 0; i < moviclips.length; i++)
{
var movis = moviclips[i];
positionMovis(movis, curr_degreesRot+movis.degreesOffset, movis.radius);
}

}

setup();
this.onEnterFrame = rolling;


ora vi chiedo, come si orientano le immagini riferite con la base al perimetro del cerchio?o meglio, tutti i clip devono essere con la base non sotto ma sul perimetro del cerchio......
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Flash Multi Gallery
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads

Thread Thread Starter Forum Replies Last Post
Actionscript 3 Getting started with a 3d image rotation, help... wuzzi2ya advanced Actionscript 3.0 0 07-11-08 22:12
Rotation of coordinates and collision with an angled surface with Flash CS3 Flep Tutorials 0 21-03-08 09:30


All times are GMT. The time now is 10:24.


Powered by vBulletin versione 3.7.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC4
Forum SiteMap


FlepStudio
by Filippo Lughi
P.IVA 03605860406