$surfaceprop: Difference between revisions
TomEdwards (talk | contribs) No edit summary |
(→Syntax) |
||
Line 13: | Line 13: | ||
Names are defined in <code><game>\scripts\surfaceproperties_manifest.txt</code> (and the files it references). For a list of Valve's stock props, see [[Material surface properties]]. | Names are defined in <code><game>\scripts\surfaceproperties_manifest.txt</code> (and the files it references). For a list of Valve's stock props, see [[Material surface properties]]. | ||
'''NOTE: In Left 4 Dead, there's it appears there is a quirky problem with the brick material surface property. The ten-odd brick textures in L4D have vmts referencing $surface_prop brick. For some reason, func_breakables with brick textures will not how bullet decals. This is the case with all the brick textures I've used. This problem also exists in the Valve survival map Last Stand, on the breakable brick wall housing the room where the event is started. It is unknown whether this issue will be fixed, or if there are any workarounds using current settings. | |||
== In materials == | == In materials == |
Revision as of 13:59, 7 September 2009
The $surfaceprop
command links the surface of either a material or model to a set of physical properties, including:
- What sounds are emitted during collisions
- What effects are emitted when the surface is shot
- Mass, buoyancy, bounciness...
- The effect of the surface on nearby sounds (reverberation, echo, absorption...)
Syntax
Syntax is the same for both models and materials:
$surfaceprop <name>
Names are defined in <game>\scripts\surfaceproperties_manifest.txt
(and the files it references). For a list of Valve's stock props, see Material surface properties.
NOTE: In Left 4 Dead, there's it appears there is a quirky problem with the brick material surface property. The ten-odd brick textures in L4D have vmts referencing $surface_prop brick. For some reason, func_breakables with brick textures will not how bullet decals. This is the case with all the brick textures I've used. This problem also exists in the Valve survival map Last Stand, on the breakable brick wall housing the room where the event is started. It is unknown whether this issue will be fixed, or if there are any workarounds using current settings.
In materials
$surfaceprop
is not linked to any particular shader, so can be used at any time.
In models
- A model's surface prop will override its material's
- It is unclear whether a model's mass is calculated from
$surfaceprop
orprop_data
- Surface props can be defined for individual bones with
$jointsurfaceprop