PDA

View Full Version : Cutting trees



Xtreme Games
01-19-2010, 10:17 PM
OK guys to cut down my trees im trying to figure out the best way to get them to cut in half and fall.I thought i could use damage modeling but then i figured no matter were the person puts the cutter it will cut in the spot i pick with i dont like.So i decided maybe i could use physics destructables(sorry if its spelt wrong haha)So witch way would be the best im gonna need the tree to start like getting cut up in a certain area.?

WHICKED
01-19-2010, 11:12 PM
Sure, this is possible.

You can actually (I think) speedtree to make a tree and then use the physics to do the "cutting" part of it.

I'll look in to it and see what I turn up.

gegebel
01-20-2010, 03:08 AM
just create a tree in SpeedTree or 3DMax and use "fracture" on it, should work.
For a tutorial on fracture, check youtube-> UDK fracture

CoffeeGrunt
01-20-2010, 11:37 AM
Fracture wouldn't really look right on it, you'd get blocky fragments falling off it...

What are PhysX Destructibles?

Sir. Polaris
01-20-2010, 12:34 PM
In the good ol days, you would make a tree in "parts" then on "death" have the parts come off, or in death you spawn in a new broken tree and let go of the parts and has the physics take over. Back in the day there was no way deform verts and create two objects from one in real time. I think DX 11 is just starting that now.

My best suggestion from a development (DX, OpenGL - not UE3 dependent thought process) would to form a class for the tree and once it's HP hits certain markers have a new model or "broken area" spawn in. This way you can show cutting of the tree, and when HP <= 0 then you push the tree over with physics (or animate it falling down), spawn in a particle effect and sound and you got a broken tree.

Old games like Operation Flashpoint did tree destruction as just a noise, geo deformation and a simple push animation with no collision. All I think that was passed was the vector of impact and how great the impact was or who it was from.

This was used to animate the falling and to see if the falling should be triggered (man cannot push over tree, tank can).

I know this isn't the effect your looking for, but I think you'll come to understand (unless this is a tree cutting simulator) that your going to be using a lot of resources for this effect as you'll have to build a tree out of wood particles and chunks to be broken off. Unless this a main selling feature you will want to look into ways to reduce the level of detail in destruction points in the tree.

EDIT: After checking your link - I think the extreme logging says it all :D

If I was doing this in OpenGL I could suggest you make a modular tree that can only be cut horizontal when you cut on a angle the program makes a check and spawns a upper and lower modular version of the tree trunk. Anything stuck to the trunk (details, branches) also stay on what ever segment holds them. Then the verts are moved to make it look like it was cut diagonally. The same is done for the bottom giving the effect of a slash cut. What ever part is not rooted to my machine or the ground, apply physics so it hits the ground - break decals appropriately. I guess that would allow you to spawn 100s of copies of "Tree Trunk" class for each cut and with the XYZ being tracked, you can toss in type and value and all that jazz so when you go to sell your wood off your truck (or even texture it) it's all done.

I dont know how you would tell unreal


if (WoodType == OAK)
{
myTexture = TextureManager.RetrieveTexture(TEXTURELIST.OAK);
}

Xtreme Games
01-20-2010, 04:14 PM
Sir. Polaris alright i get what your saying but i have no idea how to do that in unreal haha.