VehicleConstants.cs 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. /*
  2. * Copyright (c) Contributors, http://opensimulator.org/
  3. * See CONTRIBUTORS.TXT for a full list of copyright holders.
  4. *
  5. * Redistribution and use in source and binary forms, with or without
  6. * modification, are permitted provided that the following conditions are met:
  7. * * Redistributions of source code must retain the above copyright
  8. * notice, this list of conditions and the following disclaimer.
  9. * * Redistributions in binary form must reproduce the above copyright
  10. * notice, this list of conditions and the following disclaimer in the
  11. * documentation and/or other materials provided with the distribution.
  12. * * Neither the name of the OpenSimulator Project nor the
  13. * names of its contributors may be used to endorse or promote products
  14. * derived from this software without specific prior written permission.
  15. *
  16. * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY
  17. * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  18. * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  19. * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY
  20. * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
  21. * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  22. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  23. * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  24. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  25. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  26. */
  27. using System;
  28. namespace OpenSim.Region.Physics.Manager
  29. {
  30. public enum Vehicle : int
  31. {
  32. /// <summary>
  33. /// Turns off Vehicle Support
  34. /// </summary>
  35. TYPE_NONE = 0,
  36. /// <summary>
  37. /// No Angular motor, High Left right friction, No Hover, Linear Deflection 1, no angular deflection
  38. /// no vertical attractor, No banking, Identity rotation frame
  39. /// </summary>
  40. TYPE_SLED = 1,
  41. /// <summary>
  42. /// Needs Motors to be driven by timer or control events High left/right friction, No angular friction
  43. /// Linear Motor wins in a second, decays in 60 seconds. Angular motor wins in a second, decays in 8/10ths of a second
  44. /// linear deflection 2 seconds
  45. /// Vertical Attractor locked UP
  46. /// </summary>
  47. TYPE_CAR = 2,
  48. TYPE_BOAT = 3,
  49. TYPE_AIRPLANE = 4,
  50. TYPE_BALLOON = 5,
  51. LINEAR_FRICTION_TIMESCALE = 16,
  52. /// <summary>
  53. /// vector of timescales for exponential decay of angular velocity about three axis
  54. /// </summary>
  55. ANGULAR_FRICTION_TIMESCALE = 17,
  56. /// <summary>
  57. /// linear velocity vehicle will try for
  58. /// </summary>
  59. LINEAR_MOTOR_DIRECTION = 18,
  60. /// <summary>
  61. /// Offset from center of mass where linear motor forces are added
  62. /// </summary>
  63. LINEAR_MOTOR_OFFSET = 20,
  64. /// <summary>
  65. /// angular velocity that vehicle will try for
  66. /// </summary>
  67. ANGULAR_MOTOR_DIRECTION = 19,
  68. HOVER_HEIGHT = 24,
  69. HOVER_EFFICIENCY = 25,
  70. HOVER_TIMESCALE = 26,
  71. BUOYANCY = 27,
  72. LINEAR_DEFLECTION_EFFICIENCY = 28,
  73. LINEAR_DEFLECTION_TIMESCALE = 29,
  74. LINEAR_MOTOR_TIMESCALE = 30,
  75. LINEAR_MOTOR_DECAY_TIMESCALE = 31,
  76. /// <summary>
  77. /// slide between 0 and 1
  78. /// </summary>
  79. ANGULAR_DEFLECTION_EFFICIENCY = 32,
  80. ANGULAR_DEFLECTION_TIMESCALE = 33,
  81. ANGULAR_MOTOR_TIMESCALE = 34,
  82. ANGULAR_MOTOR_DECAY_TIMESCALE = 35,
  83. VERTICAL_ATTRACTION_EFFICIENCY = 36,
  84. VERTICAL_ATTRACTION_TIMESCALE = 37,
  85. BANKING_EFFICIENCY = 38,
  86. BANKING_MIX = 39,
  87. BANKING_TIMESCALE = 40,
  88. REFERENCE_FRAME = 44,
  89. BLOCK_EXIT = 45,
  90. ROLL_FRAME = 46
  91. }
  92. [Flags]
  93. public enum VehicleFlag
  94. {
  95. NO_DEFLECTION_UP = 1,
  96. LIMIT_ROLL_ONLY = 2,
  97. HOVER_WATER_ONLY = 4,
  98. HOVER_TERRAIN_ONLY = 8,
  99. HOVER_GLOBAL_HEIGHT = 16,
  100. HOVER_UP_ONLY = 32,
  101. LIMIT_MOTOR_UP = 64,
  102. MOUSELOOK_STEER = 128,
  103. MOUSELOOK_BANK = 256,
  104. CAMERA_DECOUPLED = 512,
  105. NO_X = 1024,
  106. NO_Y = 2048,
  107. NO_Z = 4096,
  108. LOCK_HOVER_HEIGHT = 8192,
  109. NO_DEFLECTION = 16392,
  110. LOCK_ROTATION = 32784
  111. }
  112. }