I am working on something similar (3D Charts) for Flex 3.0. A prototype for the same can be seen here

 

http://www.geocities.com/nihits/columnC.html

http://mannu.livejournal.com/357113.html

 

The depths are kept in a sorted list based on distance from viewer (and not based on Z coordinate value)

 

Nihit

 

 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Ralf Bokelberg
Sent: Wednesday, August 02, 2006 1:23 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Game Depth Management

 

I think, you have to create your own depth property and keep the displaylist sorted by this property.
So, instead of swapping the depth, you need to find the place in the displaylist, where a object with a certain depth has to be inserted.

Cheers,
Ralf.

On 8/1/06, John Chipps-Harding <[EMAIL PROTECTED]> wrote:

Hi:

I have just started using Flex Builder 2 and am finding authoring Actionscript 3.0 projects a dream.

I am having issues getting my head round the new way of managing depths. Specifically in an isometric game I am porting to AS3. Here is a snippet of code that shifts a sprite to a specific depth:

_sprite.swapDepths( int(newX + (newY * 900)) );

The important thing here is that I am swapping to a SPECIFIC depth... so when other movieclips redraw and swap depth they are placed in the correct depth relative to the others.

This is very loose (you could have movieclips at depth 100,000 easily) but is worked fine in AS2.

Has anybody got any ideas on how to approach this in AS3? If you think my question is too vague let me know and ill try to elaborate more.

Regards:


John




--
Ralf Bokelberg <[EMAIL PROTECTED]>
Flex & Flash Consultant based in Cologne/Germany

__._,_.___

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




__,_._,___

Reply via email to