..:: MX Studio Fóruns ::..: Por que não Funciona????? - ..:: MX Studio Fóruns ::..

Jump to content

Publicidade




ATENÇÃO

Para evitar posts desnecessários e que não influam para o andamento e desenvolvimento do fórum, clique aqui e leia todas as regras.
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Por que não Funciona?????

#1 User is offline   Paulo Victor 

  • Group: Membros
  • Posts: 3
  • Joined: 14-August 07

Posted 17 August 2007 - 03:06 PM

Possuo um swf de particulas flutuantes, e preciso carrega-lo no topo de minha Cena Principal como se fosse um header.

Ex:
+--------------------------+
| Particle.swf |
+--------------------------+
| |
| |
| Body |
| |
| |
+--------------------------+

Tentei de diversas maneiras mas infelizmente não consegui. Ele sempre é executado na Cena inteira e não apenas no topo. Tentei criar um MC vazio e carregar o swf dentro e não funfou

Link para baixar o Swf e Fla
Senha: 102030


O filme particle.swf possui 1 shape com a imagem da partícula e 2 mc, e sua cena principal é de 600x70px.

Segue o código:

MC - Sprite3
CODE
function init()
{
    makeFloats(200);
} // End of the function
function makeFloats(num)
{
    var _loc1 = num;
    for (i = 0; i < _loc1; i++)
    {
        attachMovie("particle", "p" + i, i);
    } // end of for
} // End of the function
init();


MC - Sprite2(particle)
CODE
function init()
{
    setProperty("", _x, 1000 + Math.random() * 100);
    setProperty("", _y, Math.random() * 600);
    life = Math.random() * 400;
    xt = Math.random() * 3.141593E+000;
    yt = Math.random() * 3.141593E+000;
    xdt = Math.random() / 10;
    ydt = Math.random() / 10;
    dx = -4;
    size = Math.random() * 30;
    divsize = life / size;
    rotdiv = Math.random();
} // End of the function
function float()
{
    setProperty("", _width, life / divsize);
    setProperty("", _height, life / divsize);
    xt = xt + xdt;
    yt = yt + ydt;
    setProperty("", _x, _x + dx + Math.sin(xt) * -3);
    setProperty("", _y, _y + Math.sin(yt) * 2);
    setProperty("", _rotation, _x * rotdiv);
    --life;
    if (life < 0)
    {
        init();
    } // end if
} // End of the function
this.onEnterFrame = function ()
{
    float();
};
init();


Tentei carregar o filme basicamente de 2 maneiras:


Criando um MC transparente do tamanho que escolhi e adicionando o código:

CODE
loadMovie("particle.swf", alvo);




CODE
_root.createEmptyMovieClip("alvo", 1);
loadMovie("particle.swf", alvo);
alvo._x = 100;
alvo._y = 70;


Em todas as tentativas o filme é carregado normalmente, mas ele ocupa a cena TODA! Preciso deixa apenas no topo!!!

Alguma idéia??


Obrigado!!!

0

#2 User is offline   ubi_rj 

  • Group: Moderador Global
  • Posts: 2920
  • Joined: 29-June 07

Posted 17 August 2007 - 03:37 PM

E ae amigo !!

Tudo bom ??

Faça uma máscara -> ph34r.gif

Sabe fazer ??
Tenho certeza que vai ajudar =)

Abraço e boa sorte !!
0

#3 User is offline   RANIEL 

  • Group: Membros
  • Posts: 105
  • Joined: 02-May 07

Posted 17 August 2007 - 04:53 PM

Veja se isto ajuda:
http://www.mxstudio.com.br/forum/index.php?showtopic=44149

Falous[]






Raniel Guimaraes[]
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic



Publicidade




1 User(s) are reading this topic
0 membro(s), 1 visitante(s) e 0 membros anônimo(s)