LSL_Constants.cs 50 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049
  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 vector = OpenSim.Region.ScriptEngine.Shared.LSL_Types.Vector3;
  29. using rotation = OpenSim.Region.ScriptEngine.Shared.LSL_Types.Quaternion;
  30. using LSLInteger = OpenSim.Region.ScriptEngine.Shared.LSL_Types.LSLInteger;
  31. namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
  32. {
  33. public partial class ScriptBaseClass
  34. {
  35. // SCRIPTS CONSTANTS
  36. public static readonly LSLInteger OS_APIVERSION = 23;
  37. public static readonly LSLInteger TRUE = 1;
  38. public static readonly LSLInteger FALSE = 0;
  39. public const int STATUS_PHYSICS = 1;
  40. public const int STATUS_ROTATE_X = 2;
  41. public const int STATUS_ROTATE_Y = 4;
  42. public const int STATUS_ROTATE_Z = 8;
  43. public const int STATUS_PHANTOM = 16;
  44. public const int STATUS_SANDBOX = 32;
  45. public const int STATUS_BLOCK_GRAB = 64;
  46. public const int STATUS_DIE_AT_EDGE = 128;
  47. public const int STATUS_RETURN_AT_EDGE = 256;
  48. public const int STATUS_CAST_SHADOWS = 512;
  49. public const int STATUS_BLOCK_GRAB_OBJECT = 1024;
  50. public const int AGENT = 1;
  51. public const int AGENT_BY_LEGACY_NAME = 1;
  52. public const int AGENT_BY_USERNAME = 0x10;
  53. public const int NPC = 0x20;
  54. //ApiDesc Objects running a script or physically moving
  55. public const int ACTIVE = 2;
  56. public const int PASSIVE = 4;
  57. public const int SCRIPTED = 8;
  58. public const int CONTROL_FWD = 1;
  59. public const int CONTROL_BACK = 2;
  60. public const int CONTROL_LEFT = 4;
  61. public const int CONTROL_RIGHT = 8;
  62. public const int CONTROL_UP = 16;
  63. public const int CONTROL_DOWN = 32;
  64. public const int CONTROL_ROT_LEFT = 256;
  65. public const int CONTROL_ROT_RIGHT = 512;
  66. public const int CONTROL_LBUTTON = 268435456;
  67. public const int CONTROL_ML_LBUTTON = 1073741824;
  68. //Permissions
  69. public const int PERMISSION_DEBIT = 0x02;
  70. public const int PERMISSION_TAKE_CONTROLS = 0x04;
  71. public const int PERMISSION_REMAP_CONTROLS = 0x08;
  72. public const int PERMISSION_TRIGGER_ANIMATION = 0x010;
  73. public const int PERMISSION_ATTACH = 0x20;
  74. public const int PERMISSION_RELEASE_OWNERSHIP = 0x40;
  75. public const int PERMISSION_CHANGE_LINKS = 0x80;
  76. public const int PERMISSION_CHANGE_JOINTS = 0x100;
  77. public const int PERMISSION_CHANGE_PERMISSIONS = 0x200;
  78. public const int PERMISSION_TRACK_CAMERA = 0x400;
  79. public const int PERMISSION_CONTROL_CAMERA = 0x800;
  80. public const int PERMISSION_TELEPORT = 0x1000;
  81. public const int PERMISSION_SILENT_ESTATE_MANAGEMENT = 0x4000;
  82. public const int PERMISSION_OVERRIDE_ANIMATIONS = 0x8000;
  83. public const int PERMISSION_RETURN_OBJECTS = 0x10000;
  84. public const int AGENT_FLYING = 0x1;
  85. //ApiDesc The agent has attachments
  86. public const int AGENT_ATTACHMENTS = 0x2;
  87. //ApiDesc The agent has scripted attachments
  88. public const int AGENT_SCRIPTED = 0x4;
  89. public const int AGENT_MOUSELOOK = 0x8;
  90. public const int AGENT_SITTING = 0x10;
  91. public const int AGENT_ON_OBJECT = 0x20;
  92. public const int AGENT_AWAY = 0x40;
  93. public const int AGENT_WALKING = 0x80;
  94. public const int AGENT_IN_AIR = 0x100;
  95. public const int AGENT_TYPING = 0x200;
  96. public const int AGENT_CROUCHING = 0x400;
  97. public const int AGENT_BUSY = 0x800;
  98. public const int AGENT_ALWAYS_RUN = 0x1000;
  99. public const int AGENT_AUTOPILOT = 0x2000;
  100. public const int AGENT_MALE = 0x40000000;
  101. //Particle Systems
  102. public const int PSYS_PART_INTERP_COLOR_MASK = 1;
  103. public const int PSYS_PART_INTERP_SCALE_MASK = 2;
  104. public const int PSYS_PART_BOUNCE_MASK = 4;
  105. public const int PSYS_PART_WIND_MASK = 8;
  106. public const int PSYS_PART_FOLLOW_SRC_MASK = 16;
  107. public const int PSYS_PART_FOLLOW_VELOCITY_MASK = 32;
  108. public const int PSYS_PART_TARGET_POS_MASK = 64;
  109. public const int PSYS_PART_TARGET_LINEAR_MASK = 128;
  110. public const int PSYS_PART_EMISSIVE_MASK = 256;
  111. public const int PSYS_PART_RIBBON_MASK = 1024;
  112. public const int PSYS_PART_FLAGS = 0;
  113. public const int PSYS_PART_START_COLOR = 1;
  114. public const int PSYS_PART_START_ALPHA = 2;
  115. public const int PSYS_PART_END_COLOR = 3;
  116. public const int PSYS_PART_END_ALPHA = 4;
  117. public const int PSYS_PART_START_SCALE = 5;
  118. public const int PSYS_PART_END_SCALE = 6;
  119. public const int PSYS_PART_MAX_AGE = 7;
  120. public const int PSYS_SRC_ACCEL = 8;
  121. public const int PSYS_SRC_PATTERN = 9;
  122. public const int PSYS_SRC_INNERANGLE = 10;
  123. public const int PSYS_SRC_OUTERANGLE = 11;
  124. public const int PSYS_SRC_TEXTURE = 12;
  125. public const int PSYS_SRC_BURST_RATE = 13;
  126. public const int PSYS_SRC_BURST_PART_COUNT = 15;
  127. public const int PSYS_SRC_BURST_RADIUS = 16;
  128. public const int PSYS_SRC_BURST_SPEED_MIN = 17;
  129. public const int PSYS_SRC_BURST_SPEED_MAX = 18;
  130. public const int PSYS_SRC_MAX_AGE = 19;
  131. public const int PSYS_SRC_TARGET_KEY = 20;
  132. public const int PSYS_SRC_OMEGA = 21;
  133. public const int PSYS_SRC_ANGLE_BEGIN = 22;
  134. public const int PSYS_SRC_ANGLE_END = 23;
  135. public const int PSYS_PART_BLEND_FUNC_SOURCE = 24;
  136. public const int PSYS_PART_BLEND_FUNC_DEST = 25;
  137. public const int PSYS_PART_START_GLOW = 26;
  138. public const int PSYS_PART_END_GLOW = 27;
  139. public const int PSYS_PART_BF_ONE = 0;
  140. public const int PSYS_PART_BF_ZERO = 1;
  141. public const int PSYS_PART_BF_DEST_COLOR = 2;
  142. public const int PSYS_PART_BF_SOURCE_COLOR = 3;
  143. public const int PSYS_PART_BF_ONE_MINUS_DEST_COLOR = 4;
  144. public const int PSYS_PART_BF_ONE_MINUS_SOURCE_COLOR = 5;
  145. public const int PSYS_PART_BF_SOURCE_ALPHA = 7;
  146. public const int PSYS_PART_BF_ONE_MINUS_SOURCE_ALPHA = 9;
  147. public const int PSYS_SRC_PATTERN_DROP = 1;
  148. public const int PSYS_SRC_PATTERN_EXPLODE = 2;
  149. public const int PSYS_SRC_PATTERN_ANGLE = 4;
  150. public const int PSYS_SRC_PATTERN_ANGLE_CONE = 8;
  151. public const int PSYS_SRC_PATTERN_ANGLE_CONE_EMPTY = 16;
  152. public const int VEHICLE_TYPE_NONE = 0;
  153. public const int VEHICLE_TYPE_SLED = 1;
  154. public const int VEHICLE_TYPE_CAR = 2;
  155. public const int VEHICLE_TYPE_BOAT = 3;
  156. public const int VEHICLE_TYPE_AIRPLANE = 4;
  157. public const int VEHICLE_TYPE_BALLOON = 5;
  158. public const int VEHICLE_LINEAR_FRICTION_TIMESCALE = 16;
  159. public const int VEHICLE_ANGULAR_FRICTION_TIMESCALE = 17;
  160. public const int VEHICLE_LINEAR_MOTOR_DIRECTION = 18;
  161. public const int VEHICLE_LINEAR_MOTOR_OFFSET = 20;
  162. public const int VEHICLE_ANGULAR_MOTOR_DIRECTION = 19;
  163. public const int VEHICLE_HOVER_HEIGHT = 24;
  164. public const int VEHICLE_HOVER_EFFICIENCY = 25;
  165. public const int VEHICLE_HOVER_TIMESCALE = 26;
  166. public const int VEHICLE_BUOYANCY = 27;
  167. public const int VEHICLE_LINEAR_DEFLECTION_EFFICIENCY = 28;
  168. public const int VEHICLE_LINEAR_DEFLECTION_TIMESCALE = 29;
  169. public const int VEHICLE_LINEAR_MOTOR_TIMESCALE = 30;
  170. public const int VEHICLE_LINEAR_MOTOR_DECAY_TIMESCALE = 31;
  171. public const int VEHICLE_ANGULAR_DEFLECTION_EFFICIENCY = 32;
  172. public const int VEHICLE_ANGULAR_DEFLECTION_TIMESCALE = 33;
  173. public const int VEHICLE_ANGULAR_MOTOR_TIMESCALE = 34;
  174. public const int VEHICLE_ANGULAR_MOTOR_DECAY_TIMESCALE = 35;
  175. public const int VEHICLE_VERTICAL_ATTRACTION_EFFICIENCY = 36;
  176. public const int VEHICLE_VERTICAL_ATTRACTION_TIMESCALE = 37;
  177. public const int VEHICLE_BANKING_EFFICIENCY = 38;
  178. public const int VEHICLE_BANKING_MIX = 39;
  179. public const int VEHICLE_BANKING_TIMESCALE = 40;
  180. public const int VEHICLE_REFERENCE_FRAME = 44;
  181. public const int VEHICLE_RANGE_BLOCK = 45;
  182. public const int VEHICLE_ROLL_FRAME = 46;
  183. public const int VEHICLE_FLAG_NO_DEFLECTION_UP = 1;
  184. public const int VEHICLE_FLAG_NO_FLY_UP = 1; //legacy
  185. public const int VEHICLE_FLAG_LIMIT_ROLL_ONLY = 2;
  186. public const int VEHICLE_FLAG_HOVER_WATER_ONLY = 4;
  187. public const int VEHICLE_FLAG_HOVER_TERRAIN_ONLY = 8;
  188. public const int VEHICLE_FLAG_HOVER_GLOBAL_HEIGHT = 16;
  189. public const int VEHICLE_FLAG_HOVER_UP_ONLY = 32;
  190. public const int VEHICLE_FLAG_LIMIT_MOTOR_UP = 64;
  191. public const int VEHICLE_FLAG_MOUSELOOK_STEER = 128;
  192. public const int VEHICLE_FLAG_MOUSELOOK_BANK = 256;
  193. public const int VEHICLE_FLAG_CAMERA_DECOUPLED = 512;
  194. public const int VEHICLE_FLAG_NO_X = 1024;
  195. public const int VEHICLE_FLAG_NO_Y = 2048;
  196. public const int VEHICLE_FLAG_NO_Z = 4096;
  197. public const int VEHICLE_FLAG_LOCK_HOVER_HEIGHT = 8192;
  198. public const int VEHICLE_FLAG_NO_DEFLECTION = 16392;
  199. public const int VEHICLE_FLAG_LOCK_ROTATION = 32784;
  200. public const int INVENTORY_ALL = -1;
  201. public const int INVENTORY_NONE = -1;
  202. public const int INVENTORY_TEXTURE = 0;
  203. public const int INVENTORY_SOUND = 1;
  204. public const int INVENTORY_LANDMARK = 3;
  205. public const int INVENTORY_CLOTHING = 5;
  206. public const int INVENTORY_OBJECT = 6;
  207. public const int INVENTORY_NOTECARD = 7;
  208. public const int INVENTORY_SCRIPT = 10;
  209. public const int INVENTORY_BODYPART = 13;
  210. public const int INVENTORY_ANIMATION = 20;
  211. public const int INVENTORY_GESTURE = 21;
  212. public const int INVENTORY_SETTING = 56;
  213. public const int ATTACH_CHEST = 1;
  214. public const int ATTACH_HEAD = 2;
  215. public const int ATTACH_LSHOULDER = 3;
  216. public const int ATTACH_RSHOULDER = 4;
  217. public const int ATTACH_LHAND = 5;
  218. public const int ATTACH_RHAND = 6;
  219. public const int ATTACH_LFOOT = 7;
  220. public const int ATTACH_RFOOT = 8;
  221. public const int ATTACH_BACK = 9;
  222. public const int ATTACH_PELVIS = 10;
  223. public const int ATTACH_MOUTH = 11;
  224. public const int ATTACH_CHIN = 12;
  225. public const int ATTACH_LEAR = 13;
  226. public const int ATTACH_REAR = 14;
  227. public const int ATTACH_LEYE = 15;
  228. public const int ATTACH_REYE = 16;
  229. public const int ATTACH_NOSE = 17;
  230. public const int ATTACH_RUARM = 18;
  231. public const int ATTACH_RLARM = 19;
  232. public const int ATTACH_LUARM = 20;
  233. public const int ATTACH_LLARM = 21;
  234. public const int ATTACH_RHIP = 22;
  235. public const int ATTACH_RULEG = 23;
  236. public const int ATTACH_RLLEG = 24;
  237. public const int ATTACH_LHIP = 25;
  238. public const int ATTACH_LULEG = 26;
  239. public const int ATTACH_LLLEG = 27;
  240. public const int ATTACH_BELLY = 28;
  241. public const int ATTACH_RPEC = 29;
  242. public const int ATTACH_LPEC = 30;
  243. public const int ATTACH_LEFT_PEC = 29; // Same value as ATTACH_RPEC, see https://jira.secondlife.com/browse/SVC-580
  244. public const int ATTACH_RIGHT_PEC = 30; // Same value as ATTACH_LPEC, see https://jira.secondlife.com/browse/SVC-580
  245. public const int ATTACH_HUD_CENTER_2 = 31;
  246. public const int ATTACH_HUD_TOP_RIGHT = 32;
  247. public const int ATTACH_HUD_TOP_CENTER = 33;
  248. public const int ATTACH_HUD_TOP_LEFT = 34;
  249. public const int ATTACH_HUD_CENTER_1 = 35;
  250. public const int ATTACH_HUD_BOTTOM_LEFT = 36;
  251. public const int ATTACH_HUD_BOTTOM = 37;
  252. public const int ATTACH_HUD_BOTTOM_RIGHT = 38;
  253. public const int ATTACH_NECK = 39;
  254. public const int ATTACH_AVATAR_CENTER = 40;
  255. public const int ATTACH_LHAND_RING1 = 41;
  256. public const int ATTACH_RHAND_RING1 = 42;
  257. public const int ATTACH_TAIL_BASE = 43;
  258. public const int ATTACH_TAIL_TIP = 44;
  259. public const int ATTACH_LWING = 45;
  260. public const int ATTACH_RWING = 46;
  261. public const int ATTACH_FACE_JAW = 47;
  262. public const int ATTACH_FACE_LEAR = 48;
  263. public const int ATTACH_FACE_REAR = 49;
  264. public const int ATTACH_FACE_LEYE = 50;
  265. public const int ATTACH_FACE_REYE = 51;
  266. public const int ATTACH_FACE_TONGUE = 52;
  267. public const int ATTACH_GROIN = 53;
  268. public const int ATTACH_HIND_LFOOT = 54;
  269. public const int ATTACH_HIND_RFOOT = 55;
  270. #region osMessageAttachments constants
  271. /// <summary>
  272. /// Instructs osMessageAttachements to send the message to attachments
  273. /// on every point.
  274. /// Note that is to be present on selected attachment points list, not options
  275. /// </summary>
  276. /// <remarks>
  277. /// when combined with OS_ATTACH_MSG_INVERT_POINTS, will prevent the
  278. /// message from being sent.
  279. /// if combined with OS_ATTACH_MSG_OBJECT_CREATOR or
  280. /// OS_ATTACH_MSG_SCRIPT_CREATOR, could result in no message being
  281. /// sent- this is expected behaviour.
  282. /// </remarks>
  283. public const int OS_ATTACH_MSG_ALL = -65535;
  284. /// <summary>
  285. /// Instructs osMessageAttachements to invert how the attachment points
  286. /// list should be treated (e.g. go from inclusive operation to
  287. /// exclusive operation).
  288. /// </summary>
  289. /// <remarks>
  290. /// This might be used if you want to deliver a message to one set of
  291. /// attachments and a different message to everything else. With
  292. /// this flag, you only need to build one explicit list for both calls.
  293. /// </remarks>
  294. public const int OS_ATTACH_MSG_INVERT_POINTS = 1;
  295. /// <summary>
  296. /// Instructs osMessageAttachments to only send the message to
  297. /// attachments with a CreatorID that matches the host object CreatorID
  298. /// </summary>
  299. /// <remarks>
  300. /// This would be used if distributed in an object vendor/updater server.
  301. /// </remarks>
  302. public const int OS_ATTACH_MSG_OBJECT_CREATOR = 2;
  303. /// <summary>
  304. /// Instructs osMessageAttachments to only send the message to
  305. /// attachments with a CreatorID that matches the sending script CreatorID
  306. /// </summary>
  307. /// <remarks>
  308. /// This might be used if the script is distributed independently of a
  309. /// containing object.
  310. /// </remarks>
  311. public const int OS_ATTACH_MSG_SCRIPT_CREATOR = 4;
  312. #endregion
  313. public const int LAND_LEVEL = 0;
  314. public const int LAND_RAISE = 1;
  315. public const int LAND_LOWER = 2;
  316. public const int LAND_SMOOTH = 3;
  317. public const int LAND_NOISE = 4;
  318. public const int LAND_REVERT = 5;
  319. public const int LAND_SMALL_BRUSH = 1;
  320. public const int LAND_MEDIUM_BRUSH = 2;
  321. public const int LAND_LARGE_BRUSH = 3;
  322. //Agent Dataserver
  323. public const int DATA_ONLINE = 1;
  324. public const int DATA_NAME = 2;
  325. public const int DATA_BORN = 3;
  326. public const int DATA_RATING = 4;
  327. public const int DATA_SIM_POS = 5;
  328. public const int DATA_SIM_STATUS = 6;
  329. public const int DATA_SIM_RATING = 7;
  330. public const int DATA_PAYINFO = 8;
  331. public const int DATA_SIM_RELEASE = 128;
  332. public const int ANIM_ON = 1;
  333. public const int LOOP = 2;
  334. public const int REVERSE = 4;
  335. public const int PING_PONG = 8;
  336. public const int SMOOTH = 16;
  337. public const int ROTATE = 32;
  338. public const int SCALE = 64;
  339. public const int ALL_SIDES = -1;
  340. // LINK flags
  341. public const int LINK_SET = -1;
  342. public const int LINK_ROOT = 1;
  343. public const int LINK_ALL_OTHERS = -2;
  344. public const int LINK_ALL_CHILDREN = -3;
  345. public const int LINK_THIS = -4;
  346. public const int CHANGED_INVENTORY = 1;
  347. public const int CHANGED_COLOR = 2;
  348. public const int CHANGED_SHAPE = 4;
  349. public const int CHANGED_SCALE = 8;
  350. public const int CHANGED_TEXTURE = 16;
  351. public const int CHANGED_LINK = 32;
  352. public const int CHANGED_ALLOWED_DROP = 64;
  353. public const int CHANGED_OWNER = 128;
  354. public const int CHANGED_REGION = 256;
  355. public const int CHANGED_TELEPORT = 512;
  356. public const int CHANGED_REGION_RESTART = 1024;
  357. public const int CHANGED_REGION_START = 1024; //LL Changed the constant from CHANGED_REGION_RESTART
  358. public const int CHANGED_MEDIA = 2048;
  359. //ApiDesc opensim specific
  360. public const int CHANGED_ANIMATION = 16384;
  361. //ApiDesc opensim specific
  362. public const int CHANGED_POSITION = 32768;
  363. public const int TYPE_INVALID = 0;
  364. public const int TYPE_INTEGER = 1;
  365. public const int TYPE_FLOAT = 2;
  366. public const int TYPE_STRING = 3;
  367. public const int TYPE_KEY = 4;
  368. public const int TYPE_VECTOR = 5;
  369. public const int TYPE_ROTATION = 6;
  370. //XML RPC Remote Data Channel
  371. public const int REMOTE_DATA_CHANNEL = 1;
  372. public const int REMOTE_DATA_REQUEST = 2;
  373. public const int REMOTE_DATA_REPLY = 3;
  374. //llHTTPRequest
  375. public const int HTTP_METHOD = 0;
  376. public const int HTTP_MIMETYPE = 1;
  377. public const int HTTP_BODY_MAXLENGTH = 2;
  378. public const int HTTP_VERIFY_CERT = 3;
  379. public const int HTTP_VERBOSE_THROTTLE = 4;
  380. public const int HTTP_CUSTOM_HEADER = 5;
  381. public const int HTTP_PRAGMA_NO_CACHE = 6;
  382. // llSetContentType
  383. public const int CONTENT_TYPE_TEXT = 0; //text/plain
  384. public const int CONTENT_TYPE_HTML = 1; //text/html
  385. public const int CONTENT_TYPE_XML = 2; //application/xml
  386. public const int CONTENT_TYPE_XHTML = 3; //application/xhtml+xml
  387. public const int CONTENT_TYPE_ATOM = 4; //application/atom+xml
  388. public const int CONTENT_TYPE_JSON = 5; //application/json
  389. public const int CONTENT_TYPE_LLSD = 6; //application/llsd+xml
  390. public const int CONTENT_TYPE_FORM = 7; //application/x-www-form-urlencoded
  391. public const int CONTENT_TYPE_RSS = 8; //application/rss+xml
  392. //parameters comand flags
  393. public const int PRIM_MATERIAL = 2;
  394. public const int PRIM_PHYSICS = 3;
  395. public const int PRIM_TEMP_ON_REZ = 4;
  396. public const int PRIM_PHANTOM = 5;
  397. public const int PRIM_POSITION = 6;
  398. public const int PRIM_SIZE = 7;
  399. public const int PRIM_ROTATION = 8;
  400. public const int PRIM_TYPE = 9;
  401. // gap 10-16
  402. public const int PRIM_TEXTURE = 17;
  403. public const int PRIM_COLOR = 18;
  404. public const int PRIM_BUMP_SHINY = 19;
  405. public const int PRIM_FULLBRIGHT = 20;
  406. public const int PRIM_FLEXIBLE = 21;
  407. public const int PRIM_TEXGEN = 22;
  408. public const int PRIM_POINT_LIGHT = 23;
  409. //ApiDesc not supported
  410. public const int PRIM_CAST_SHADOWS = 24; // Not implemented, here for completeness sake
  411. public const int PRIM_GLOW = 25;
  412. public const int PRIM_TEXT = 26;
  413. public const int PRIM_NAME = 27;
  414. public const int PRIM_DESC = 28;
  415. public const int PRIM_ROT_LOCAL = 29;
  416. public const int PRIM_PHYSICS_SHAPE_TYPE = 30;
  417. public const int PRIM_PHYSICS_MATERIAL = 31; // apparently not on SL wiki
  418. public const int PRIM_OMEGA = 32;
  419. public const int PRIM_POS_LOCAL = 33;
  420. public const int PRIM_LINK_TARGET = 34;
  421. public const int PRIM_SLICE = 35;
  422. public const int PRIM_SPECULAR = 36;
  423. public const int PRIM_NORMAL = 37;
  424. public const int PRIM_ALPHA_MODE = 38;
  425. //ApiDesc not supported
  426. public const int PRIM_ALLOW_UNSIT = 39; // experiences related. unsupported
  427. //ApiDesc not supported
  428. public const int PRIM_SCRIPTED_SIT_ONLY = 40; // experiences related. unsupported
  429. public const int PRIM_SIT_TARGET = 41;
  430. public const int PRIM_PROJECTOR = 42;
  431. public const int PRIM_REFLECTION_PROBE = 44;
  432. public const int PRIM_GLTF_NORMAL = 45;
  433. public const int PRIM_GLTF_EMISSIVE = 46;
  434. public const int PRIM_GLTF_METALLIC_ROUGHNESS = 47;
  435. public const int PRIM_GLTF_BASE_COLOR = 48;
  436. public const int PRIM_RENDER_MATERIAL = 49;
  437. // parameters
  438. public const int PRIM_ALPHA_MODE_NONE = 0;
  439. public const int PRIM_ALPHA_MODE_BLEND = 1;
  440. public const int PRIM_ALPHA_MODE_MASK = 2;
  441. public const int PRIM_ALPHA_MODE_EMISSIVE = 3;
  442. public const int PRIM_TEXGEN_DEFAULT = 0;
  443. public const int PRIM_TEXGEN_PLANAR = 1;
  444. public const int PRIM_TYPE_BOX = 0;
  445. public const int PRIM_TYPE_CYLINDER = 1;
  446. public const int PRIM_TYPE_PRISM = 2;
  447. public const int PRIM_TYPE_SPHERE = 3;
  448. public const int PRIM_TYPE_TORUS = 4;
  449. public const int PRIM_TYPE_TUBE = 5;
  450. public const int PRIM_TYPE_RING = 6;
  451. public const int PRIM_TYPE_SCULPT = 7;
  452. public const int PRIM_HOLE_DEFAULT = 0;
  453. public const int PRIM_HOLE_CIRCLE = 16;
  454. public const int PRIM_HOLE_SQUARE = 32;
  455. public const int PRIM_HOLE_TRIANGLE = 48;
  456. public const int PRIM_MATERIAL_STONE = 0;
  457. public const int PRIM_MATERIAL_METAL = 1;
  458. public const int PRIM_MATERIAL_GLASS = 2;
  459. public const int PRIM_MATERIAL_WOOD = 3;
  460. public const int PRIM_MATERIAL_FLESH = 4;
  461. public const int PRIM_MATERIAL_PLASTIC = 5;
  462. public const int PRIM_MATERIAL_RUBBER = 6;
  463. public const int PRIM_MATERIAL_LIGHT = 7;
  464. public const int PRIM_SHINY_NONE = 0;
  465. public const int PRIM_SHINY_LOW = 1;
  466. public const int PRIM_SHINY_MEDIUM = 2;
  467. public const int PRIM_SHINY_HIGH = 3;
  468. public const int PRIM_BUMP_NONE = 0;
  469. public const int PRIM_BUMP_BRIGHT = 1;
  470. public const int PRIM_BUMP_DARK = 2;
  471. public const int PRIM_BUMP_WOOD = 3;
  472. public const int PRIM_BUMP_BARK = 4;
  473. public const int PRIM_BUMP_BRICKS = 5;
  474. public const int PRIM_BUMP_CHECKER = 6;
  475. public const int PRIM_BUMP_CONCRETE = 7;
  476. public const int PRIM_BUMP_TILE = 8;
  477. public const int PRIM_BUMP_STONE = 9;
  478. public const int PRIM_BUMP_DISKS = 10;
  479. public const int PRIM_BUMP_GRAVEL = 11;
  480. public const int PRIM_BUMP_BLOBS = 12;
  481. public const int PRIM_BUMP_SIDING = 13;
  482. public const int PRIM_BUMP_LARGETILE = 14;
  483. public const int PRIM_BUMP_STUCCO = 15;
  484. public const int PRIM_BUMP_SUCTION = 16;
  485. public const int PRIM_BUMP_WEAVE = 17;
  486. public const int PRIM_SCULPT_TYPE_SPHERE = 1;
  487. public const int PRIM_SCULPT_TYPE_TORUS = 2;
  488. public const int PRIM_SCULPT_TYPE_PLANE = 3;
  489. public const int PRIM_SCULPT_TYPE_CYLINDER = 4;
  490. public const int PRIM_SCULPT_TYPE_MESH = 5;
  491. public const int PRIM_SCULPT_FLAG_ANIMESH = 0x20;
  492. public const int PRIM_SCULPT_FLAG_INVERT = 0x40;
  493. public const int PRIM_SCULPT_FLAG_MIRROR = 0x80;
  494. //ApiDesc Auxiliar to clear flags keeping scultp type
  495. public const int PRIM_SCULPT_TYPE_MASK = 0x07; // auxiliar mask
  496. public const int PRIM_PHYSICS_SHAPE_PRIM = 0;
  497. public const int PRIM_PHYSICS_SHAPE_NONE = 1;
  498. public const int PRIM_PHYSICS_SHAPE_CONVEX = 2;
  499. // PRIM_REFLECTION_PROBE flags
  500. public const int PRIM_REFLECTION_PROBE_BOX = 1; // 1
  501. public const int PRIM_REFLECTION_PROBE_DYNAMIC = 2; // 2
  502. public const int PROFILE_NONE = 0;
  503. public const int PROFILE_SCRIPT_MEMORY = 1;
  504. public const int MASK_BASE = 0;
  505. public const int MASK_OWNER = 1;
  506. public const int MASK_GROUP = 2;
  507. public const int MASK_EVERYONE = 3;
  508. public const int MASK_NEXT = 4;
  509. public const int PERM_TRANSFER = 0x2000;
  510. public const int PERM_MODIFY = 0x4000;
  511. public const int PERM_COPY = 0x8000;
  512. public const int PERM_MOVE = 0x80000;
  513. public const int PERM_ALL = 0x7fffffff;
  514. public const int PARCEL_MEDIA_COMMAND_STOP = 0;
  515. public const int PARCEL_MEDIA_COMMAND_PAUSE = 1;
  516. public const int PARCEL_MEDIA_COMMAND_PLAY = 2;
  517. public const int PARCEL_MEDIA_COMMAND_LOOP = 3;
  518. public const int PARCEL_MEDIA_COMMAND_TEXTURE = 4;
  519. public const int PARCEL_MEDIA_COMMAND_URL = 5;
  520. public const int PARCEL_MEDIA_COMMAND_TIME = 6;
  521. public const int PARCEL_MEDIA_COMMAND_AGENT = 7;
  522. public const int PARCEL_MEDIA_COMMAND_UNLOAD = 8;
  523. public const int PARCEL_MEDIA_COMMAND_AUTO_ALIGN = 9;
  524. public const int PARCEL_MEDIA_COMMAND_TYPE = 10;
  525. public const int PARCEL_MEDIA_COMMAND_SIZE = 11;
  526. public const int PARCEL_MEDIA_COMMAND_DESC = 12;
  527. public const int PARCEL_FLAG_ALLOW_FLY = 0x1; // parcel allows flying
  528. public const int PARCEL_FLAG_ALLOW_SCRIPTS = 0x2; // parcel allows outside scripts
  529. public const int PARCEL_FLAG_ALLOW_LANDMARK = 0x8; // parcel allows landmarks to be created
  530. public const int PARCEL_FLAG_ALLOW_TERRAFORM = 0x10; // parcel allows anyone to terraform the land
  531. public const int PARCEL_FLAG_ALLOW_DAMAGE = 0x20; // parcel allows damage
  532. public const int PARCEL_FLAG_ALLOW_CREATE_OBJECTS = 0x40; // parcel allows anyone to create objects
  533. public const int PARCEL_FLAG_USE_ACCESS_GROUP = 0x100; // parcel limits access to a group
  534. public const int PARCEL_FLAG_USE_ACCESS_LIST = 0x200; // parcel limits access to a list of residents
  535. public const int PARCEL_FLAG_USE_BAN_LIST = 0x400; // parcel uses a ban list, including restricting access based on payment info
  536. public const int PARCEL_FLAG_USE_LAND_PASS_LIST = 0x800; // parcel allows passes to be purchased
  537. public const int PARCEL_FLAG_LOCAL_SOUND_ONLY = 0x8000; // parcel restricts spatialized sound to the parcel
  538. public const int PARCEL_FLAG_RESTRICT_PUSHOBJECT = 0x200000; // parcel restricts llPushObject
  539. public const int PARCEL_FLAG_ALLOW_GROUP_SCRIPTS = 0x2000000; // parcel allows scripts owned by group
  540. public const int PARCEL_FLAG_ALLOW_CREATE_GROUP_OBJECTS = 0x4000000; // parcel allows group object creation
  541. public const int PARCEL_FLAG_ALLOW_ALL_OBJECT_ENTRY = 0x8000000; // parcel allows objects owned by any user to enter
  542. public const int PARCEL_FLAG_ALLOW_GROUP_OBJECT_ENTRY = 0x10000000; // parcel allows with the same group to enter
  543. public const int REGION_FLAG_ALLOW_DAMAGE = 0x1; // region is entirely damage enabled
  544. public const int REGION_FLAG_FIXED_SUN = 0x10; // region has a fixed sun position
  545. public const int REGION_FLAG_BLOCK_TERRAFORM = 0x40; // region terraforming disabled
  546. public const int REGION_FLAG_SANDBOX = 0x100; // region is a sandbox
  547. public const int REGION_FLAG_DISABLE_COLLISIONS = 0x1000; // region has disabled collisions
  548. public const int REGION_FLAG_DISABLE_PHYSICS = 0x4000; // region has disabled physics
  549. public const int REGION_FLAG_BLOCK_FLY = 0x80000; // region blocks flying
  550. public const int REGION_FLAG_ALLOW_DIRECT_TELEPORT = 0x100000; // region allows direct teleports
  551. public const int REGION_FLAG_RESTRICT_PUSHOBJECT = 0x400000; // region restricts llPushObject
  552. //llManageEstateAccess
  553. public const int ESTATE_ACCESS_ALLOWED_AGENT_ADD = 0;
  554. public const int ESTATE_ACCESS_ALLOWED_AGENT_REMOVE = 1;
  555. public const int ESTATE_ACCESS_ALLOWED_GROUP_ADD = 2;
  556. public const int ESTATE_ACCESS_ALLOWED_GROUP_REMOVE = 3;
  557. public const int ESTATE_ACCESS_BANNED_AGENT_ADD = 4;
  558. public const int ESTATE_ACCESS_BANNED_AGENT_REMOVE = 5;
  559. public static readonly LSLInteger PAY_HIDE = -1;
  560. public static readonly LSLInteger PAY_DEFAULT = -2;
  561. public const string NULL_KEY = "00000000-0000-0000-0000-000000000000";
  562. public const string EOF = "\n\n\n";
  563. public const string NAK = "\n\u0015\n";
  564. public const double PI = 3.14159274f;
  565. public const double TWO_PI = 6.28318548f;
  566. public const double PI_BY_TWO = 1.57079637f;
  567. public const double DEG_TO_RAD = 0.01745329238f;
  568. public const double RAD_TO_DEG = 57.29578f;
  569. public const double SQRT2 = 1.414213538f;
  570. public const int STRING_TRIM_HEAD = 1;
  571. public const int STRING_TRIM_TAIL = 2;
  572. public const int STRING_TRIM = 3;
  573. public const int LIST_STAT_RANGE = 0;
  574. public const int LIST_STAT_MIN = 1;
  575. public const int LIST_STAT_MAX = 2;
  576. public const int LIST_STAT_MEAN = 3;
  577. public const int LIST_STAT_MEDIAN = 4;
  578. public const int LIST_STAT_STD_DEV = 5;
  579. public const int LIST_STAT_SUM = 6;
  580. public const int LIST_STAT_SUM_SQUARES = 7;
  581. public const int LIST_STAT_NUM_COUNT = 8;
  582. public const int LIST_STAT_GEOMETRIC_MEAN = 9;
  583. public const int LIST_STAT_HARMONIC_MEAN = 100;
  584. //ParcelPrim Categories
  585. public const int PARCEL_COUNT_TOTAL = 0;
  586. public const int PARCEL_COUNT_OWNER = 1;
  587. public const int PARCEL_COUNT_GROUP = 2;
  588. public const int PARCEL_COUNT_OTHER = 3;
  589. public const int PARCEL_COUNT_SELECTED = 4;
  590. public const int PARCEL_COUNT_TEMP = 5;
  591. public const int DEBUG_CHANNEL = 0x7FFFFFFF;
  592. public const int PUBLIC_CHANNEL = 0x00000000;
  593. // Constants for llGetObjectDetails
  594. public const int OBJECT_UNKNOWN_DETAIL = -1;
  595. public const int OBJECT_NAME = 1;
  596. public const int OBJECT_DESC = 2;
  597. public const int OBJECT_POS = 3;
  598. public const int OBJECT_ROT = 4;
  599. public const int OBJECT_VELOCITY = 5;
  600. public const int OBJECT_OWNER = 6;
  601. public const int OBJECT_GROUP = 7;
  602. public const int OBJECT_CREATOR = 8;
  603. public const int OBJECT_RUNNING_SCRIPT_COUNT = 9;
  604. public const int OBJECT_TOTAL_SCRIPT_COUNT = 10;
  605. public const int OBJECT_SCRIPT_MEMORY = 11;
  606. public const int OBJECT_SCRIPT_TIME = 12;
  607. public const int OBJECT_PRIM_EQUIVALENCE = 13;
  608. public const int OBJECT_SERVER_COST = 14;
  609. public const int OBJECT_STREAMING_COST = 15;
  610. public const int OBJECT_PHYSICS_COST = 16;
  611. public const int OBJECT_CHARACTER_TIME = 17;
  612. public const int OBJECT_ROOT = 18;
  613. public const int OBJECT_ATTACHED_POINT = 19;
  614. public const int OBJECT_PATHFINDING_TYPE = 20;
  615. public const int OBJECT_PHYSICS = 21;
  616. public const int OBJECT_PHANTOM = 22;
  617. public const int OBJECT_TEMP_ON_REZ = 23;
  618. public const int OBJECT_RENDER_WEIGHT = 24;
  619. public const int OBJECT_HOVER_HEIGHT = 25;
  620. public const int OBJECT_BODY_SHAPE_TYPE = 26;
  621. public const int OBJECT_LAST_OWNER_ID = 27;
  622. public const int OBJECT_CLICK_ACTION = 28;
  623. public const int OBJECT_OMEGA = 29;
  624. public const int OBJECT_PRIM_COUNT = 30;
  625. public const int OBJECT_TOTAL_INVENTORY_COUNT = 31;
  626. public const int OBJECT_REZZER_KEY = 32;
  627. public const int OBJECT_GROUP_TAG = 33;
  628. public const int OBJECT_TEMP_ATTACHED = 34;
  629. public const int OBJECT_ATTACHED_SLOTS_AVAILABLE = 35;
  630. public const int OBJECT_CREATION_TIME = 36;
  631. public const int OBJECT_SELECT_COUNT = 37;
  632. public const int OBJECT_SIT_COUNT = 38;
  633. public const int OBJECT_ANIMATED_COUNT = 39;
  634. public const int OBJECT_ANIMATED_SLOTS_AVAILABLE = 40;
  635. public const int OBJECT_ACCOUNT_LEVEL = 41;
  636. public const int OBJECT_MATERIAL = 42;
  637. public const int OBJECT_MASS = 43;
  638. public const int OBJECT_TEXT = 44;
  639. public const int OBJECT_REZ_TIME = 45;
  640. public const int OBJECT_LINK_NUMBER = 46;
  641. public const int OBJECT_SCALE = 47;
  642. public const int OBJECT_TEXT_COLOR = 48;
  643. public const int OBJECT_TEXT_ALPHA = 49;
  644. // Pathfinding types
  645. //ApiDesc not supported
  646. public const int OPT_OTHER = -1;
  647. //ApiDesc not supported
  648. public const int OPT_LEGACY_LINKSET = 0;
  649. //ApiDesc not supported
  650. public const int OPT_AVATAR = 1;
  651. //ApiDesc not supported
  652. public const int OPT_CHARACTER = 2;
  653. //ApiDesc not supported
  654. public const int OPT_WALKABLE = 3;
  655. //ApiDesc not supported
  656. public const int OPT_STATIC_OBSTACLE = 4;
  657. //ApiDesc not supported
  658. public const int OPT_MATERIAL_VOLUME = 5;
  659. //ApiDesc not supported
  660. public const int OPT_EXCLUSION_VOLUME = 6;
  661. // for llGetAgentList
  662. public const int AGENT_LIST_PARCEL = 0x1;
  663. public const int AGENT_LIST_PARCEL_OWNER = 2;
  664. public const int AGENT_LIST_REGION = 4;
  665. public const int AGENT_LIST_EXCLUDENPC = 0x4000000;
  666. // Can not be public const?
  667. public static readonly vector ZERO_VECTOR = new vector(0.0, 0.0, 0.0);
  668. public static readonly rotation ZERO_ROTATION = new rotation(0.0, 0.0, 0.0, 1.0);
  669. // constants for llSetCameraParams
  670. public const int CAMERA_PITCH = 0;
  671. public const int CAMERA_FOCUS_OFFSET = 1;
  672. public const int CAMERA_FOCUS_OFFSET_X = 2;
  673. public const int CAMERA_FOCUS_OFFSET_Y = 3;
  674. public const int CAMERA_FOCUS_OFFSET_Z = 4;
  675. public const int CAMERA_POSITION_LAG = 5;
  676. public const int CAMERA_FOCUS_LAG = 6;
  677. public const int CAMERA_DISTANCE = 7;
  678. public const int CAMERA_BEHINDNESS_ANGLE = 8;
  679. public const int CAMERA_BEHINDNESS_LAG = 9;
  680. public const int CAMERA_POSITION_THRESHOLD = 10;
  681. public const int CAMERA_FOCUS_THRESHOLD = 11;
  682. public const int CAMERA_ACTIVE = 12;
  683. public const int CAMERA_POSITION = 13;
  684. public const int CAMERA_POSITION_X = 14;
  685. public const int CAMERA_POSITION_Y = 15;
  686. public const int CAMERA_POSITION_Z = 16;
  687. public const int CAMERA_FOCUS = 17;
  688. public const int CAMERA_FOCUS_X = 18;
  689. public const int CAMERA_FOCUS_Y = 19;
  690. public const int CAMERA_FOCUS_Z = 20;
  691. public const int CAMERA_POSITION_LOCKED = 21;
  692. public const int CAMERA_FOCUS_LOCKED = 22;
  693. // constants for llGetParcelDetails
  694. public const int PARCEL_DETAILS_NAME = 0;
  695. public const int PARCEL_DETAILS_DESC = 1;
  696. public const int PARCEL_DETAILS_OWNER = 2;
  697. public const int PARCEL_DETAILS_GROUP = 3;
  698. public const int PARCEL_DETAILS_AREA = 4;
  699. public const int PARCEL_DETAILS_ID = 5;
  700. public const int PARCEL_DETAILS_SEE_AVATARS = 6;
  701. public const int PARCEL_DETAILS_PRIM_CAPACITY = 7;
  702. public const int PARCEL_DETAILS_PRIM_USED = 8;
  703. public const int PARCEL_DETAILS_LANDING_POINT = 9;
  704. public const int PARCEL_DETAILS_LANDING_LOOKAT = 10;
  705. public const int PARCEL_DETAILS_TP_ROUTING = 11;
  706. public const int PARCEL_DETAILS_FLAGS = 12;
  707. public const int PARCEL_DETAILS_SCRIPT_DANGER = 13;
  708. // constants for llGetParcelDetails os specific
  709. public const int PARCEL_DETAILS_DWELL = 64;
  710. public const int PARCEL_DETAILS_GETCLAIMDATE = 65;
  711. public const int PARCEL_DETAILS_GEOMETRICCENTER = 66;
  712. //osSetParcelDetails
  713. public const int PARCEL_DETAILS_ANY_AVATAR_SOUNDS = 7;
  714. public const int PARCEL_DETAILS_GROUP_SOUNDS = 8;
  715. public const int PARCEL_DETAILS_CLAIMDATE = 10;
  716. // constants for llSetClickAction
  717. public const int CLICK_ACTION_NONE = 0;
  718. public const int CLICK_ACTION_TOUCH = 0;
  719. public const int CLICK_ACTION_SIT = 1;
  720. public const int CLICK_ACTION_BUY = 2;
  721. public const int CLICK_ACTION_PAY = 3;
  722. public const int CLICK_ACTION_OPEN = 4;
  723. public const int CLICK_ACTION_PLAY = 5;
  724. public const int CLICK_ACTION_OPEN_MEDIA = 6;
  725. public const int CLICK_ACTION_ZOOM = 7;
  726. public const int CLICK_ACTION_DISABLED = 8;
  727. // constants for the llDetectedTouch* functions
  728. public const int TOUCH_INVALID_FACE = -1;
  729. public static readonly vector TOUCH_INVALID_TEXCOORD = new vector(-1.0, -1.0, 0.0);
  730. public static readonly vector TOUCH_INVALID_VECTOR = ZERO_VECTOR;
  731. // constants for llGetPrimMediaParams/llSetPrimMediaParams
  732. public const int PRIM_MEDIA_ALT_IMAGE_ENABLE = 0;
  733. public const int PRIM_MEDIA_CONTROLS = 1;
  734. public const int PRIM_MEDIA_CURRENT_URL = 2;
  735. public const int PRIM_MEDIA_HOME_URL = 3;
  736. public const int PRIM_MEDIA_AUTO_LOOP = 4;
  737. public const int PRIM_MEDIA_AUTO_PLAY = 5;
  738. public const int PRIM_MEDIA_AUTO_SCALE = 6;
  739. public const int PRIM_MEDIA_AUTO_ZOOM = 7;
  740. public const int PRIM_MEDIA_FIRST_CLICK_INTERACT = 8;
  741. public const int PRIM_MEDIA_WIDTH_PIXELS = 9;
  742. public const int PRIM_MEDIA_HEIGHT_PIXELS = 10;
  743. public const int PRIM_MEDIA_WHITELIST_ENABLE = 11;
  744. public const int PRIM_MEDIA_WHITELIST = 12;
  745. public const int PRIM_MEDIA_PERMS_INTERACT = 13;
  746. public const int PRIM_MEDIA_PERMS_CONTROL = 14;
  747. public const int PRIM_MEDIA_CONTROLS_STANDARD = 0;
  748. public const int PRIM_MEDIA_CONTROLS_MINI = 1;
  749. public const int PRIM_MEDIA_PERM_NONE = 0;
  750. public const int PRIM_MEDIA_PERM_OWNER = 1;
  751. public const int PRIM_MEDIA_PERM_GROUP = 2;
  752. public const int PRIM_MEDIA_PERM_ANYONE = 4;
  753. public const int DENSITY = 1;
  754. public const int FRICTION = 2;
  755. public const int RESTITUTION = 4;
  756. public const int GRAVITY_MULTIPLIER = 8;
  757. // extra constants for llSetPrimMediaParams
  758. public static readonly LSLInteger LSL_STATUS_OK = 0;
  759. public static readonly LSLInteger LSL_STATUS_MALFORMED_PARAMS = 1000;
  760. public static readonly LSLInteger LSL_STATUS_TYPE_MISMATCH = 1001;
  761. public static readonly LSLInteger LSL_STATUS_BOUNDS_ERROR = 1002;
  762. public static readonly LSLInteger LSL_STATUS_NOT_FOUND = 1003;
  763. public static readonly LSLInteger LSL_STATUS_NOT_SUPPORTED = 1004;
  764. public static readonly LSLInteger LSL_STATUS_INTERNAL_ERROR = 1999;
  765. public static readonly LSLInteger LSL_STATUS_WHITELIST_FAILED = 2001;
  766. // Constants for default textures
  767. public const string TEXTURE_BLANK = "5748decc-f629-461c-9a36-a35a221fe21f";
  768. public const string TEXTURE_DEFAULT = "89556747-24cb-43ed-920b-47caed15465f";
  769. public const string TEXTURE_PLYWOOD = "89556747-24cb-43ed-920b-47caed15465f";
  770. public const string TEXTURE_TRANSPARENT = "8dcd4a48-2d37-4909-9f78-f7a9eb4ef903";
  771. public const string TEXTURE_MEDIA = "8b5fec65-8d8d-9dc5-cda8-8fdf2716e361";
  772. // Constants for osGetRegionStats this must match StatsIndex in SimStats.cs
  773. public const int STATS_TIME_DILATION = 0;
  774. public const int STATS_SIM_FPS = 1;
  775. public const int STATS_PHYSICS_FPS = 2;
  776. public const int STATS_AGENT_UPDATES = 3;
  777. public const int STATS_ROOT_AGENTS = 4;
  778. public const int STATS_CHILD_AGENTS = 5;
  779. public const int STATS_TOTAL_PRIMS = 6;
  780. public const int STATS_ACTIVE_PRIMS = 7;
  781. public const int STATS_FRAME_MS = 8;
  782. public const int STATS_NET_MS = 9;
  783. public const int STATS_PHYSICS_MS = 10;
  784. public const int STATS_IMAGE_MS = 11;
  785. public const int STATS_OTHER_MS = 12;
  786. public const int STATS_IN_PACKETS_PER_SECOND = 13;
  787. public const int STATS_OUT_PACKETS_PER_SECOND = 14;
  788. public const int STATS_UNACKED_BYTES = 15;
  789. public const int STATS_AGENT_MS = 16;
  790. public const int STATS_PENDING_DOWNLOADS = 17;
  791. public const int STATS_PENDING_UPLOADS = 18;
  792. public const int STATS_ACTIVE_SCRIPTS = 19;
  793. public const int STATS_SIM_SLEEP = 20;
  794. public const int STATS_SCRIPT_EPS = 28;
  795. public const int STATS_SCRIPT_TIME = 37;
  796. public const int STATS_SCRIPT_LPS = 38;
  797. public const int STATS_SCRIPT_NPCS = 47;
  798. // Constants for osNpc* functions
  799. public const int OS_NPC_FLY = 0;
  800. public const int OS_NPC_NO_FLY = 1;
  801. public const int OS_NPC_LAND_AT_TARGET = 2;
  802. public const int OS_NPC_RUNNING = 4;
  803. public const int OS_NPC_SIT_NOW = 0;
  804. public const int OS_NPC_CREATOR_OWNED = 0x1;
  805. public const int OS_NPC_NOT_OWNED = 0x2;
  806. public const int OS_NPC_SENSE_AS_AGENT = 0x4;
  807. public const int OS_NPC_OBJECT_GROUP = 0x08;
  808. public const string URL_REQUEST_GRANTED = "URL_REQUEST_GRANTED";
  809. public const string URL_REQUEST_DENIED = "URL_REQUEST_DENIED";
  810. public static readonly LSLInteger RC_REJECT_TYPES = 0;
  811. public static readonly LSLInteger RC_DETECT_PHANTOM = 1;
  812. public static readonly LSLInteger RC_DATA_FLAGS = 2;
  813. public static readonly LSLInteger RC_MAX_HITS = 3;
  814. public static readonly LSLInteger RC_REJECT_AGENTS = 1;
  815. public static readonly LSLInteger RC_REJECT_PHYSICAL = 2;
  816. public static readonly LSLInteger RC_REJECT_NONPHYSICAL = 4;
  817. public static readonly LSLInteger RC_REJECT_LAND = 8;
  818. public static readonly LSLInteger RC_REJECT_HOST = 0x20000000;
  819. public static readonly LSLInteger RC_REJECT_HOSTGROUP = 0x40000000;
  820. public static readonly LSLInteger RC_GET_NORMAL = 1;
  821. public static readonly LSLInteger RC_GET_ROOT_KEY = 2;
  822. public static readonly LSLInteger RC_GET_LINK_NUM = 4;
  823. public static readonly LSLInteger RCERR_UNKNOWN = -1;
  824. public static readonly LSLInteger RCERR_SIM_PERF_LOW = -2;
  825. public static readonly LSLInteger RCERR_CAST_TIME_EXCEEDED = -3;
  826. public const int KFM_MODE = 1;
  827. public const int KFM_LOOP = 1;
  828. public const int KFM_REVERSE = 3;
  829. public const int KFM_FORWARD = 0;
  830. public const int KFM_PING_PONG = 2;
  831. public const int KFM_DATA = 2;
  832. public const int KFM_TRANSLATION = 2;
  833. public const int KFM_ROTATION = 1;
  834. public const int KFM_COMMAND = 0;
  835. public const int KFM_CMD_PLAY = 0;
  836. public const int KFM_CMD_STOP = 1;
  837. public const int KFM_CMD_PAUSE = 2;
  838. public const string JSON_INVALID = "\uFDD0";
  839. public const string JSON_OBJECT = "\uFDD1";
  840. public const string JSON_ARRAY = "\uFDD2";
  841. public const string JSON_NUMBER = "\uFDD3";
  842. public const string JSON_STRING = "\uFDD4";
  843. public const string JSON_NULL = "\uFDD5";
  844. public const string JSON_TRUE = "\uFDD6";
  845. public const string JSON_FALSE = "\uFDD7";
  846. public const string JSON_DELETE = "\uFDD8";
  847. public const string JSON_APPEND = "-1";
  848. /// <summary>
  849. /// process name parameter as regex
  850. /// </summary>
  851. public const int OS_LISTEN_REGEX_NAME = 0x1;
  852. /// <summary>
  853. /// process message parameter as regex
  854. /// </summary>
  855. public const int OS_LISTEN_REGEX_MESSAGE = 0x2;
  856. // Constants for osTeleportObject
  857. //ApiDesc osTeleportObject no flags
  858. public const int OSTPOBJ_NONE = 0x0;
  859. //ApiDesc osTeleportObject flag: stop at destination
  860. public const int OSTPOBJ_STOPATTARGET = 0x1;
  861. //ApiDesc osTeleportObject flag: stop at jump point if tp fails
  862. public const int OSTPOBJ_STOPONFAIL = 0x2;
  863. //ApiDesc osTeleportObject flag: the rotation is the final rotation, otherwise is a added rotation
  864. public const int OSTPOBJ_SETROT = 0x4;
  865. //ApiDesc osLocalTeleportAgent no flags
  866. public const int OS_LTPAG_NONE = 0x0;
  867. //ApiDesc osLocalTeleportAgent use velocity
  868. public const int OS_LTPAG_USEVEL = 0x1;
  869. //ApiDesc osLocalTeleportAgent use lookat
  870. public const int OS_LTPAG_USELOOKAT = 0x2;
  871. //ApiDesc osLocalTeleportAgent align lookat to velocity
  872. public const int OS_LTPAG_ALGNLV = 0x4;
  873. //ApiDesc osLocalTeleportAgent force fly
  874. public const int OS_LTPAG_FORCEFLY = 0x8;
  875. //ApiDesc osLocalTeleportAgent force no fly
  876. public const int OS_LTPAG_FORCENOFLY = 0x16;
  877. // Constants for Windlight
  878. public const int WL_WATER_COLOR = 0;
  879. public const int WL_WATER_FOG_DENSITY_EXPONENT = 1;
  880. public const int WL_UNDERWATER_FOG_MODIFIER = 2;
  881. public const int WL_REFLECTION_WAVELET_SCALE = 3;
  882. public const int WL_FRESNEL_SCALE = 4;
  883. public const int WL_FRESNEL_OFFSET = 5;
  884. public const int WL_REFRACT_SCALE_ABOVE = 6;
  885. public const int WL_REFRACT_SCALE_BELOW = 7;
  886. public const int WL_BLUR_MULTIPLIER = 8;
  887. public const int WL_BIG_WAVE_DIRECTION = 9;
  888. public const int WL_LITTLE_WAVE_DIRECTION = 10;
  889. public const int WL_NORMAL_MAP_TEXTURE = 11;
  890. public const int WL_HORIZON = 12;
  891. public const int WL_HAZE_HORIZON = 13;
  892. public const int WL_BLUE_DENSITY = 14;
  893. public const int WL_HAZE_DENSITY = 15;
  894. public const int WL_DENSITY_MULTIPLIER = 16;
  895. public const int WL_DISTANCE_MULTIPLIER = 17;
  896. public const int WL_MAX_ALTITUDE = 18;
  897. public const int WL_SUN_MOON_COLOR = 19;
  898. public const int WL_AMBIENT = 20;
  899. public const int WL_EAST_ANGLE = 21;
  900. public const int WL_SUN_GLOW_FOCUS = 22;
  901. public const int WL_SUN_GLOW_SIZE = 23;
  902. public const int WL_SCENE_GAMMA = 24;
  903. public const int WL_STAR_BRIGHTNESS = 25;
  904. public const int WL_CLOUD_COLOR = 26;
  905. public const int WL_CLOUD_XY_DENSITY = 27;
  906. public const int WL_CLOUD_COVERAGE = 28;
  907. public const int WL_CLOUD_SCALE = 29;
  908. public const int WL_CLOUD_DETAIL_XY_DENSITY = 30;
  909. public const int WL_CLOUD_SCROLL_X = 31;
  910. public const int WL_CLOUD_SCROLL_Y = 32;
  911. public const int WL_CLOUD_SCROLL_Y_LOCK = 33;
  912. public const int WL_CLOUD_SCROLL_X_LOCK = 34;
  913. public const int WL_DRAW_CLASSIC_CLOUDS = 35;
  914. public const int WL_SUN_MOON_POSITION = 36;
  915. public const string IMG_USE_BAKED_HEAD = "5a9f4a74-30f2-821c-b88d-70499d3e7183";
  916. public const string IMG_USE_BAKED_UPPER = "ae2de45c-d252-50b8-5c6e-19f39ce79317";
  917. public const string IMG_USE_BAKED_LOWER = "24daea5f-0539-cfcf-047f-fbc40b2786ba";
  918. public const string IMG_USE_BAKED_EYES = "52cc6bb6-2ee5-e632-d3ad-50197b1dcb8a";
  919. public const string IMG_USE_BAKED_SKIRT = "43529ce8-7faa-ad92-165a-bc4078371687";
  920. public const string IMG_USE_BAKED_HAIR = "09aac1fb-6bce-0bee-7d44-caac6dbb6c63";
  921. public const string IMG_USE_BAKED_LEFTARM = "ff62763f-d60a-9855-890b-0c96f8f8cd98";
  922. public const string IMG_USE_BAKED_LEFTLEG = "8e915e25-31d1-cc95-ae08-d58a47488251";
  923. public const string IMG_USE_BAKED_AUX1 = "9742065b-19b5-297c-858a-29711d539043";
  924. public const string IMG_USE_BAKED_AUX2 = "03642e83-2bd1-4eb9-34b4-4c47ed586d2d";
  925. public const string IMG_USE_BAKED_AUX3 = "edd51b77-fc10-ce7a-4b3d-011dfc349e4f";
  926. // llTargetedEmail
  927. public const int TARGETED_EMAIL_ROOT_CREATOR = 1;
  928. public const int TARGETED_EMAIL_OBJECT_OWNER = 2;
  929. public const int NPCLOOKAT_NONE = 0;
  930. public const int NPCLOOKAT_IDLE = 1;
  931. public const int NPCLOOKAT_LISTEN = 2;
  932. public const int NPCLOOKAT_FREELOOK = 3;
  933. public const int NPCLOOKAT_RESPOND = 4;
  934. public const int NPCLOOKAT_HOVER = 5;
  935. public const int NPCLOOKAT_CONVERSATION = 6;
  936. public const int NPCLOOKAT_SELECT = 7;
  937. public const int NPCLOOKAT_FOCUS = 8;
  938. public const int NPCLOOKAT_MOUSELOOK = 9;
  939. public const int NPCLOOKAT_CLEAR = 10;
  940. // future ?? linkset_data event
  941. public const int LINKSETDATA_RESET = 0;
  942. public const int LINKSETDATA_UPDATE = 1;
  943. public const int LINKSETDATA_DELETE = 2;
  944. public const int LINKSETDATA_MULTIDELETE = 3;
  945. public const int LINKSETDATA_OK = 0;
  946. public const int LINKSETDATA_EMEMORY = 1;
  947. public const int LINKSETDATA_ENOKEY = 2;
  948. public const int LINKSETDATA_EPROTECTED = 3;
  949. public const int LINKSETDATA_NOTFOUND = 4;
  950. public const int LINKSETDATA_NOUPDATE = 5;
  951. //llLinkPlaySound flags
  952. public const int SOUND_PLAY = 0;
  953. public const int SOUND_LOOP = 1;
  954. public const int SOUND_TRIGGER = 2;
  955. public const int SOUND_SYNC = 4;
  956. }
  957. }