Jump to content
jen

Custom Vegetation Model Physics

Recommended Posts

Right now there's no way of creating simpler models for Trees (Vegetation) in the editor. The cone, box, sphere, presets that are accessible from the model viewer can't be edited and are scaled based on the entire size of the model including the leaves. Leaves shouldn't be included in the physics of vegetation models.

Can you make it so the Physics generator ignore surfaces that have disabled Pick mode on their materials? 

It's not urgent but may be desirable in the future, the current solution is to use a cone physics model angle upside down with the pointy end facing downwards. Even then, the cone still sort of bulges outwards and the character controller can't get close to the tree bark.

Copying the Pine tree physics model is also a viable solution but I doubt if the average users will figure this out. They'll end up complaining in the end anyway.

Ideally you just want a thin cylinder on the middle of the model.

This tree creates a problem especially for Vehicles, it would also be a problem for character controllers if a tree has low hanging leaves:

fn3WcuG.png

 

The cone model:

eXaR3fA.png

 

Another solution: create a blank map, add terrain, place the tree vegetation, add a cylinder on the map and export the map as OBJ.

Import the obj into Leadwerks and generate physics model. Copy the physics model and replace the tree physics with this model.

8IN1Tek.png

Share this post


Link to post

You create another model (together with your other model) which is just the shape you want to use for your physics collision.  You name it collisionhull or collisionhull01 or whatever as long as it starts with collisionhull.  This way you can have multiple shapes with your model.  Leadwerks will automatically take that mesh or meshes and make it your physics shape(s) when you import it.

More info here:
https://www.leadwerks.com/learn?page=Tutorials_Editor_Models-and-Animation

You can use collisionmesh the same way and that one doesn't have to be concave but it also can't move (which for trees or other static level items is fine).

  • Upvote 2

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...