29 using System.Collections.Generic;
31 using OpenSim.Framework;
33 namespace OpenSim.
Region.Framework.Scenes
35 public static class SOPMaterialData
37 public enum SopMaterial :
int
49 private struct MaterialData
51 public float friction;
53 public MaterialData(
float f,
float b)
60 private static MaterialData[] m_materialdata = {
61 new MaterialData(0.8f,0.4f),
62 new MaterialData(0.3f,0.4f),
63 new MaterialData(0.2f,0.7f),
64 new MaterialData(0.6f,0.5f),
65 new MaterialData(0.9f,0.3f),
66 new MaterialData(0.4f,0.7f),
67 new MaterialData(0.9f,0.95f),
68 new MaterialData(0.0f,0.0f)
73 get {
return (
Material)(m_materialdata.Length - 1); }
76 public static float friction(
Material material)
78 int indx = (int)material;
79 if (indx < m_materialdata.Length)
80 return (m_materialdata[indx].friction);
85 public static float bounce(
Material material)
87 int indx = (int)material;
88 if (indx < m_materialdata.Length)
89 return (m_materialdata[indx].bounce);
Material
Material type for a primitive