aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared
diff options
context:
space:
mode:
authorCharles Krinke2008-07-03 15:34:05 +0000
committerCharles Krinke2008-07-03 15:34:05 +0000
commit103093cf114bfb64715f21b0f239b3ffe78fd873 (patch)
tree21cf245a5c22ab8e4f4dc508cb6e96714a3cabb0 /OpenSim/Region/ScriptEngine/Shared
parentMantis#1653. Thank you kindly, Vytek for a patch that: (diff)
downloadopensim-SC_OLD-103093cf114bfb64715f21b0f239b3ffe78fd873.zip
opensim-SC_OLD-103093cf114bfb64715f21b0f239b3ffe78fd873.tar.gz
opensim-SC_OLD-103093cf114bfb64715f21b0f239b3ffe78fd873.tar.bz2
opensim-SC_OLD-103093cf114bfb64715f21b0f239b3ffe78fd873.tar.xz
Mantis#1654. Thank you kindly, Matth for a patch that:
Updates llGetPrimitiveParams() and associated files.
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs32
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs1
2 files changed, 17 insertions, 16 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index d540e13..1579233 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -5391,56 +5391,56 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5391 5391
5392 switch (code) 5392 switch (code)
5393 { 5393 {
5394 case 2: // PRIM_MATERIAL 5394 case (int)ScriptBaseClass.PRIM_MATERIAL:
5395 res.Add(new LSL_Types.LSLInteger(m_host.Material)); 5395 res.Add(new LSL_Types.LSLInteger(m_host.Material));
5396 break; 5396 break;
5397 5397
5398 case 3: // PRIM_PHYSICS 5398 case (int)ScriptBaseClass.PRIM_PHYSICS:
5399 if ((m_host.GetEffectiveObjectFlags() & (uint)LLObject.ObjectFlags.Physics) != 0) 5399 if ((m_host.GetEffectiveObjectFlags() & (uint)LLObject.ObjectFlags.Physics) != 0)
5400 res.Add(new LSL_Types.LSLInteger(1)); 5400 res.Add(new LSL_Types.LSLInteger(1));
5401 else 5401 else
5402 res.Add(new LSL_Types.LSLInteger(0)); 5402 res.Add(new LSL_Types.LSLInteger(0));
5403 break; 5403 break;
5404 5404
5405 case 4: // PRIM_TEMP_ON_REZ 5405 case (int)ScriptBaseClass.PRIM_TEMP_ON_REZ:
5406 if ((m_host.GetEffectiveObjectFlags() & (uint)LLObject.ObjectFlags.TemporaryOnRez) != 0) 5406 if ((m_host.GetEffectiveObjectFlags() & (uint)LLObject.ObjectFlags.TemporaryOnRez) != 0)
5407 res.Add(new LSL_Types.LSLInteger(1)); 5407 res.Add(new LSL_Types.LSLInteger(1));
5408 else 5408 else
5409 res.Add(new LSL_Types.LSLInteger(0)); 5409 res.Add(new LSL_Types.LSLInteger(0));
5410 break; 5410 break;
5411 5411
5412 case 5: // PRIM_PHANTOM 5412 case (int)ScriptBaseClass.PRIM_PHANTOM:
5413 if ((m_host.GetEffectiveObjectFlags() & (uint)LLObject.ObjectFlags.Phantom) != 0) 5413 if ((m_host.GetEffectiveObjectFlags() & (uint)LLObject.ObjectFlags.Phantom) != 0)
5414 res.Add(new LSL_Types.LSLInteger(1)); 5414 res.Add(new LSL_Types.LSLInteger(1));
5415 else 5415 else
5416 res.Add(new LSL_Types.LSLInteger(0)); 5416 res.Add(new LSL_Types.LSLInteger(0));
5417 break; 5417 break;
5418 5418
5419 case 6: // PRIM_POSITION 5419 case (int)ScriptBaseClass.PRIM_POSITION:
5420 res.Add(new LSL_Types.Vector3(m_host.AbsolutePosition.X, 5420 res.Add(new LSL_Types.Vector3(m_host.AbsolutePosition.X,
5421 m_host.AbsolutePosition.Y, 5421 m_host.AbsolutePosition.Y,
5422 m_host.AbsolutePosition.Z)); 5422 m_host.AbsolutePosition.Z));
5423 break; 5423 break;
5424 5424
5425 case 7: // PRIM_SIZE 5425 case (int)ScriptBaseClass.PRIM_SIZE:
5426 res.Add(new LSL_Types.Vector3(m_host.Scale.X, 5426 res.Add(new LSL_Types.Vector3(m_host.Scale.X,
5427 m_host.Scale.Y, 5427 m_host.Scale.Y,
5428 m_host.Scale.Z)); 5428 m_host.Scale.Z));
5429 break; 5429 break;
5430 5430
5431 case 8: // PRIM_ROTATION 5431 case (int)ScriptBaseClass.PRIM_ROTATION:
5432 res.Add(new LSL_Types.Quaternion(m_host.RotationOffset.X, 5432 res.Add(new LSL_Types.Quaternion(m_host.RotationOffset.X,
5433 m_host.RotationOffset.Y, 5433 m_host.RotationOffset.Y,
5434 m_host.RotationOffset.Z, 5434 m_host.RotationOffset.Z,
5435 m_host.RotationOffset.W)); 5435 m_host.RotationOffset.W));
5436 break; 5436 break;
5437 5437
5438 case 9: // PRIM_TYPE 5438 case (int)ScriptBaseClass.PRIM_TYPE:
5439 // TODO-------------- 5439 // TODO--------------
5440 res.Add(new LSL_Types.LSLInteger(0)); 5440 res.Add(new LSL_Types.LSLInteger(0));
5441 break; 5441 break;
5442 5442
5443 case 17: // PRIM_TEXTURE 5443 case (int)ScriptBaseClass.PRIM_TEXTURE:
5444 if (remain < 1) 5444 if (remain < 1)
5445 return res; 5445 return res;
5446 5446
@@ -5461,7 +5461,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5461 res.Add(new LSL_Types.LSLFloat(texface.Rotation)); 5461 res.Add(new LSL_Types.LSLFloat(texface.Rotation));
5462 break; 5462 break;
5463 5463
5464 case 18: // PRIM_COLOR 5464 case (int)ScriptBaseClass.PRIM_COLOR:
5465 if (remain < 1) 5465 if (remain < 1)
5466 return res; 5466 return res;
5467 5467
@@ -5479,7 +5479,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5479 res.Add(new LSL_Types.LSLFloat((texcolor.A * 255) / 255)); 5479 res.Add(new LSL_Types.LSLFloat((texcolor.A * 255) / 255));
5480 break; 5480 break;
5481 5481
5482 case 19: // PRIM_BUMP_SHINY 5482 case (int)ScriptBaseClass.PRIM_BUMP_SHINY:
5483 // TODO-------------- 5483 // TODO--------------
5484 if (remain < 1) 5484 if (remain < 1)
5485 return res; 5485 return res;
@@ -5490,7 +5490,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5490 res.Add(new LSL_Types.LSLInteger(0)); 5490 res.Add(new LSL_Types.LSLInteger(0));
5491 break; 5491 break;
5492 5492
5493 case 20: // PRIM_FULLBRIGHT 5493 case (int)ScriptBaseClass.PRIM_FULLBRIGHT:
5494 // TODO-------------- 5494 // TODO--------------
5495 if (remain < 1) 5495 if (remain < 1)
5496 return res; 5496 return res;
@@ -5500,7 +5500,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5500 res.Add(new LSL_Types.LSLInteger(0)); 5500 res.Add(new LSL_Types.LSLInteger(0));
5501 break; 5501 break;
5502 5502
5503 case 21: // PRIM_FLEXIBLE 5503 case (int)ScriptBaseClass.PRIM_FLEXIBLE:
5504 PrimitiveBaseShape shape = m_host.Shape; 5504 PrimitiveBaseShape shape = m_host.Shape;
5505 5505
5506 if (shape.FlexiEntry) 5506 if (shape.FlexiEntry)
@@ -5517,7 +5517,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5517 shape.FlexiForceZ)); 5517 shape.FlexiForceZ));
5518 break; 5518 break;
5519 5519
5520 case 22: // PRIM_TEXGEN 5520 case (int)ScriptBaseClass.PRIM_TEXGEN:
5521 // TODO-------------- 5521 // TODO--------------
5522 // (PRIM_TEXGEN_DEFAULT, PRIM_TEXGEN_PLANAR) 5522 // (PRIM_TEXGEN_DEFAULT, PRIM_TEXGEN_PLANAR)
5523 if (remain < 1) 5523 if (remain < 1)
@@ -5528,7 +5528,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5528 res.Add(new LSL_Types.LSLInteger(0)); 5528 res.Add(new LSL_Types.LSLInteger(0));
5529 break; 5529 break;
5530 5530
5531 case 23: // PRIM_POINT_LIGHT: 5531 case (int)ScriptBaseClass.PRIM_POINT_LIGHT:
5532 shape = m_host.Shape; 5532 shape = m_host.Shape;
5533 5533
5534 if (shape.LightEntry) 5534 if (shape.LightEntry)
@@ -5543,7 +5543,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5543 res.Add(new LSL_Types.LSLFloat(shape.LightFalloff)); // falloff 5543 res.Add(new LSL_Types.LSLFloat(shape.LightFalloff)); // falloff
5544 break; 5544 break;
5545 5545
5546 case 24: // PRIM_GLOW 5546 case (int)ScriptBaseClass.PRIM_GLOW:
5547 // TODO-------------- 5547 // TODO--------------
5548 if (remain < 1) 5548 if (remain < 1)
5549 return res; 5549 return res;
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
index 69be69b..c086f22 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
@@ -290,6 +290,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
290 public const int PRIM_TEXGEN = 22; 290 public const int PRIM_TEXGEN = 22;
291 public const int PRIM_CAST_SHADOWS = 24; // Not implemented, here for completeness sake 291 public const int PRIM_CAST_SHADOWS = 24; // Not implemented, here for completeness sake
292 public const int PRIM_POINT_LIGHT = 23; // Huh? 292 public const int PRIM_POINT_LIGHT = 23; // Huh?
293 public const int PRIM_GLOW = 25;
293 public const int PRIM_TEXGEN_DEFAULT = 0; 294 public const int PRIM_TEXGEN_DEFAULT = 0;
294 public const int PRIM_TEXGEN_PLANAR = 1; 295 public const int PRIM_TEXGEN_PLANAR = 1;
295 296