Difference between revisions of "Material Volumes"
Hyper Mole (talk | contribs) |
|||
(4 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
==About Material Volumes== | ==About Material Volumes== | ||
*The Material Volume [[Pathfinding_Tools_in_the_Second_Life_Viewer#Example_use_3|attribute]] for Pathfinding creates phantom objects that can be set to change the walkability coefficients of an area of the navmesh. Walkability coefficients are multipliers that may be applied to the speed of a pathfinding character. | *The Material Volume [[Pathfinding_Tools_in_the_Second_Life_Viewer#Example_use_3|attribute]] for [[Pathfinding]] creates phantom objects that can be set to change the walkability coefficients of an area of the navmesh. Walkability coefficients are multipliers that may be applied to the speed of a pathfinding character. | ||
*Pathfinding characters will choose the fastest and closest path available to them. (add video of PF cube choosing 100% walkability path around a MV) | *Pathfinding characters will choose the fastest and closest path available to them. (add video of PF cube choosing 100% walkability path around a MV) | ||
*Material Volumes are visible in the [[Pathfinding_NavMesh|navigation mesh view]] as | *Material Volumes are visible in the [[Pathfinding_NavMesh|navigation mesh view]] as transparent purple objects. | ||
*Like exclusion volumes, material volumes must be comprised of physically convex prims or meshes. | |||
[[File:Material_volume_001.png|none| | [[File:Material_volume_001.png|none|300x225px]] | ||
Notes: | |||
Because walkability coefficients are a per-linkset and not per-prim property, if you would like a linkset (or the terrain) to have different coefficients in different areas, you will need to use material phantoms. Material phantoms are convex phantom prims (strictly, they are linksets made up of any combination of convex prims) which “paint” their walkability coefficients over any part of the navmesh they intersect. For example, if you have a single linkset house and would like your butler to be able to move anywhere but your pet to stay out of your dining room, you would start by setting the house walkable and leaving the default coefficients at “A=100%, B=100%”. Then, you would rez a box that encompasses the floor and any other walkable surfaces in the dining room, set it to “Material Phantom”, and give it coefficients “A=100%, B=0%”. After rebaking the navmesh, areas contained in the material phantom will be walkable for CHARACTER_TYPE_A but unwalkable for CHARACTER_TYPE_B. | |||
'''Important''' | |||
If you find yourself needing to nest material phantoms (perhaps to provide a more gradual change from one walkability value to another), here is the rule that we use to resolve conflicting values: If a point on the navmesh is encompassed by multiple material phantoms, and one of those phantoms is fully enclosed (in X, Y, and Z) by /all/ of the others, then the innermost phantom’s coefficients are used. If none of the phantoms are fully enclosed by all of the others, the linkset’s /original/ walkability coefficients are used. | |||
---- | ---- | ||
Return to [[Good_Building_Practices]] | Return to [[Good_Building_Practices]] |
Latest revision as of 18:03, 27 August 2012
About Material Volumes
- The Material Volume attribute for Pathfinding creates phantom objects that can be set to change the walkability coefficients of an area of the navmesh. Walkability coefficients are multipliers that may be applied to the speed of a pathfinding character.
- Pathfinding characters will choose the fastest and closest path available to them. (add video of PF cube choosing 100% walkability path around a MV)
- Material Volumes are visible in the navigation mesh view as transparent purple objects.
- Like exclusion volumes, material volumes must be comprised of physically convex prims or meshes.
Notes: Because walkability coefficients are a per-linkset and not per-prim property, if you would like a linkset (or the terrain) to have different coefficients in different areas, you will need to use material phantoms. Material phantoms are convex phantom prims (strictly, they are linksets made up of any combination of convex prims) which “paint” their walkability coefficients over any part of the navmesh they intersect. For example, if you have a single linkset house and would like your butler to be able to move anywhere but your pet to stay out of your dining room, you would start by setting the house walkable and leaving the default coefficients at “A=100%, B=100%”. Then, you would rez a box that encompasses the floor and any other walkable surfaces in the dining room, set it to “Material Phantom”, and give it coefficients “A=100%, B=0%”. After rebaking the navmesh, areas contained in the material phantom will be walkable for CHARACTER_TYPE_A but unwalkable for CHARACTER_TYPE_B.
Important If you find yourself needing to nest material phantoms (perhaps to provide a more gradual change from one walkability value to another), here is the rule that we use to resolve conflicting values: If a point on the navmesh is encompassed by multiple material phantoms, and one of those phantoms is fully enclosed (in X, Y, and Z) by /all/ of the others, then the innermost phantom’s coefficients are used. If none of the phantoms are fully enclosed by all of the others, the linkset’s /original/ walkability coefficients are used.
Return to Good_Building_Practices