D'oh, yes, in fact i will try that, and to use some color transform to
do the fading, hope this is posibble.

On 21 ago, 09:09, Peter Kapelyan <[email protected]> wrote:
> You can try mySprite.distanceTo(mycamera) to get a distance and then do
> something like:
>
> myalpha = 1-(dist/1000);
>
> Of course you need some Math.min/max to make sure it stays between 0 and 1.
> So just a couple lines of code the most.
>
> -Pete
>
>
>
> On Fri, Aug 21, 2009 at 10:02 AM, desgraci <[email protected]> wrote:
>
> > hi, im looking for a way to dssapear my directional sprite of the
> > scene smoothly, like my preivous post, at the end the depth material
> > an a z filter were necesarry, i was wondering if this could be made
> > with the sprite directional, for example:
>
> >                        var lostSoul:LostSoul;
> >                        lostSoul = new LostSoul();
> >                        lostSoul.renderer=new BasicRenderer(zdepth);
> >                        scene.addChild(lostSoul);
>
> > ofc this doenst works, or i woulndt be bothering here :p
> > where i can use the DepthBitmapMaterial, cause the class only allows
> > BitmapMaterials...
>
> > if this is not posible, theres a way to control the alpha acording to
> > the distance of the camera?
>
> --
> ___________________
>
> Actionscript 3.0 Flash 3D Graphics Engine
>
> HTTP://AWAY3D.COM

Reply via email to