Link to home
Start Free TrialLog in
Avatar of Dreammonkey
DreammonkeyFlag for Belgium

asked on

papervision best way to add 2d images to 3d plane

I've been working on my own terrain generator, you can check it at:
http://www.jazz-band.be/dMonkeyFlash/Terrain3D/ 

I want to add 2d images (movieclips) (the buildings + trees) to the 3d planes (the ground tiles)(also movieclips).
I'm using script below, adding all the assets to a MovieClip and then using this movieclip as MovieMaterial => Plane ;

!!! trouble is when the child is bigger then the Plane it erases other planes behind it... !!!

I want to keep the buildings 2d but I want papervision to scale them so they look OK...

ideas are welcome

PS: I'm convinced my method is not the best practice:

tile=new earth(); // the ground tile , = mc pulled out of the library
var tree:trees = new trees(); //the trees, = mc pulled out of the library
tile.addChild(tree);
 
var build:Towers1 = new Towers1(); // a building pulled out of the library
tile.addChild(build);
 
mam=new MovieMaterial(tile);
mam.interactive=true;
mam.smooth=true;
mam.animated=true;
 
// this is whayt matters for this question the rest can be checked at Q_24122261

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of pepsichris
pepsichris
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Dreammonkey

ASKER

Hi Chris,

thanks for that quick response, you're right about the tranceparancy thing, I should 've checked the source ...

Thing is :  there is still a bug :
surf to the url I posted , don't mingle with the settings in the options.
just hit generate, you'll see that underneath the 'Castle' the earth has been removed, I'm not sure why this is...

You'll notice the lighthouses at the bottom, they're generated in the same manner as the castle,
could there be a way to make them look better, that is, react 3d-ish to the scrolling?

I know I'm not being pretty generous on code-terms, the project is rather dear to me...
If you like, I'm on messenger deemonkeyjazz at hot .

BIG Thanks anyway, your answer was correct !
Thanks again !