BasicPhysicsActor.cs 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304
  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. using System.Collections.Generic;
  29. using Nini.Config;
  30. using OpenMetaverse;
  31. using OpenSim.Framework;
  32. using OpenSim.Region.Physics.Manager;
  33. namespace OpenSim.Region.Physics.BasicPhysicsPlugin
  34. {
  35. public class BasicActor : PhysicsActor
  36. {
  37. private Vector3 _size;
  38. public BasicActor(Vector3 size)
  39. {
  40. Size = size;
  41. }
  42. public override int PhysicsActorType
  43. {
  44. get { return (int) ActorTypes.Agent; }
  45. set { return; }
  46. }
  47. public override Vector3 RotationalVelocity { get; set; }
  48. public override bool SetAlwaysRun
  49. {
  50. get { return false; }
  51. set { return; }
  52. }
  53. public override uint LocalID
  54. {
  55. set { return; }
  56. }
  57. public override bool Grabbed
  58. {
  59. set { return; }
  60. }
  61. public override bool Selected
  62. {
  63. set { return; }
  64. }
  65. public override float Buoyancy
  66. {
  67. get { return 0f; }
  68. set { return; }
  69. }
  70. public override bool FloatOnWater
  71. {
  72. set { return; }
  73. }
  74. public override bool IsPhysical
  75. {
  76. get { return false; }
  77. set { return; }
  78. }
  79. public override bool ThrottleUpdates
  80. {
  81. get { return false; }
  82. set { return; }
  83. }
  84. public override bool Flying { get; set; }
  85. public override bool IsColliding { get; set; }
  86. public override bool CollidingGround
  87. {
  88. get { return false; }
  89. set { return; }
  90. }
  91. public override bool CollidingObj
  92. {
  93. get { return false; }
  94. set { return; }
  95. }
  96. public override bool Stopped
  97. {
  98. get { return false; }
  99. }
  100. public override Vector3 Position { get; set; }
  101. public override Vector3 Size { get; set; }
  102. public override PrimitiveBaseShape Shape
  103. {
  104. set { return; }
  105. }
  106. public override float Mass
  107. {
  108. get { return 0f; }
  109. }
  110. public override Vector3 Force
  111. {
  112. get { return Vector3.Zero; }
  113. set { return; }
  114. }
  115. public override int VehicleType
  116. {
  117. get { return 0; }
  118. set { return; }
  119. }
  120. public override void VehicleFloatParam(int param, float value)
  121. {
  122. }
  123. public override void VehicleVectorParam(int param, Vector3 value)
  124. {
  125. }
  126. public override void VehicleRotationParam(int param, Quaternion rotation)
  127. {
  128. }
  129. public override void VehicleFlags(int param, bool remove)
  130. {
  131. }
  132. public override void SetVolumeDetect(int param)
  133. {
  134. }
  135. public override Vector3 CenterOfMass
  136. {
  137. get { return Vector3.Zero; }
  138. }
  139. public override Vector3 GeometricCenter
  140. {
  141. get { return Vector3.Zero; }
  142. }
  143. public override Vector3 Velocity { get; set; }
  144. public override Vector3 Torque
  145. {
  146. get { return Vector3.Zero; }
  147. set { return; }
  148. }
  149. public override float CollisionScore
  150. {
  151. get { return 0f; }
  152. set { }
  153. }
  154. public override Quaternion Orientation
  155. {
  156. get { return Quaternion.Identity; }
  157. set { }
  158. }
  159. public override Vector3 Acceleration { get; set; }
  160. public override bool Kinematic
  161. {
  162. get { return true; }
  163. set { }
  164. }
  165. public override void link(PhysicsActor obj)
  166. {
  167. }
  168. public override void delink()
  169. {
  170. }
  171. public override void LockAngularMotion(Vector3 axis)
  172. {
  173. }
  174. public override void AddForce(Vector3 force, bool pushforce)
  175. {
  176. }
  177. public override void AddAngularForce(Vector3 force, bool pushforce)
  178. {
  179. }
  180. public override void SetMomentum(Vector3 momentum)
  181. {
  182. }
  183. public override void CrossingFailure()
  184. {
  185. }
  186. public override Vector3 PIDTarget
  187. {
  188. set { return; }
  189. }
  190. public override bool PIDActive
  191. {
  192. set { return; }
  193. }
  194. public override float PIDTau
  195. {
  196. set { return; }
  197. }
  198. public override float PIDHoverHeight
  199. {
  200. set { return; }
  201. }
  202. public override bool PIDHoverActive
  203. {
  204. set { return; }
  205. }
  206. public override PIDHoverType PIDHoverType
  207. {
  208. set { return; }
  209. }
  210. public override float PIDHoverTau
  211. {
  212. set { return; }
  213. }
  214. public override Quaternion APIDTarget
  215. {
  216. set { return; }
  217. }
  218. public override bool APIDActive
  219. {
  220. set { return; }
  221. }
  222. public override float APIDStrength
  223. {
  224. set { return; }
  225. }
  226. public override float APIDDamping
  227. {
  228. set { return; }
  229. }
  230. public override void SubscribeEvents(int ms)
  231. {
  232. }
  233. public override void UnSubscribeEvents()
  234. {
  235. }
  236. public override bool SubscribedEvents()
  237. {
  238. return false;
  239. }
  240. }
  241. }