aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/OptionalModules/Scripting
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/OptionalModules/Scripting/Minimodule/IObject.cs45
-rw-r--r--OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs16
2 files changed, 55 insertions, 6 deletions
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/IObject.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/IObject.cs
index 21efc6d..d3eeffb 100644
--- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/IObject.cs
+++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/IObject.cs
@@ -33,14 +33,35 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
33{ 33{
34 public interface IObject 34 public interface IObject
35 { 35 {
36 /// <summary>
37 /// Returns whether or not this object is still in the world.
38 /// Eg, if you store an IObject reference, however the object
39 /// is deleted before you use it, it will throw a NullReference
40 /// exception. 'Exists' allows you to check the object is still
41 /// in play before utilizing it.
42 /// </summary>
36 bool Exists { get; } 43 bool Exists { get; }
44
45 /// <summary>
46 /// The local region-unique ID for this object.
47 /// </summary>
37 uint LocalID { get; } 48 uint LocalID { get; }
49
50 /// <summary>
51 /// The global 'world-unique' ID for this object.
52 /// (Note, may not actually be world unique)
53 /// </summary>
38 UUID GlobalID { get; } 54 UUID GlobalID { get; }
39 55
56 /// <summary>
57 /// The name of this Object.
58 /// </summary>
40 String Name { get; set; } 59 String Name { get; set; }
41 String Description { get; set; }
42 60
43 61 /// <summary>
62 /// The description assigned to this object.
63 /// </summary>
64 String Description { get; set; }
44 65
45 /// <summary> 66 /// <summary>
46 /// Returns the root object of a linkset. If this object is the root, it will return itself. 67 /// Returns the root object of a linkset. If this object is the root, it will return itself.
@@ -67,19 +88,35 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
67 /// <summary> 88 /// <summary>
68 /// The rotation of the object relative to the Scene 89 /// The rotation of the object relative to the Scene
69 /// </summary> 90 /// </summary>
70 Quaternion Rotation { get; set; } 91 Quaternion WorldRotation { get; set; }
92
93 /// <summary>
94 /// The rotation of the object relative to a parent object
95 /// If root, works the same as WorldRotation
96 /// </summary>
97 Quaternion OffsetRotation { get; set; }
71 98
72 /// <summary> 99 /// <summary>
73 /// The position of the object relative to the Scene 100 /// The position of the object relative to the Scene
74 /// </summary> 101 /// </summary>
75 Vector3 Position { get; set; } 102 Vector3 WorldPosition { get; set; }
76 103
104 /// <summary>
105 /// The position of the object relative to a parent object
106 /// If root, works the same as WorldPosition
107 /// </summary>
108 Vector3 OffsetPosition { get; set; }
77 109
78 Vector3 SitTarget { get; set; } 110 Vector3 SitTarget { get; set; }
79 String SitTargetText { get; set; } 111 String SitTargetText { get; set; }
80 112
81 String TouchText { get; set; } 113 String TouchText { get; set; }
82 114
115 /// <summary>
116 /// Text to be associated with this object, in the
117 /// Second Life(r) viewer, this is shown above the
118 /// object.
119 /// </summary>
83 String Text { get; set; } 120 String Text { get; set; }
84 121
85 bool IsPhysical { get; set; } // SetStatus(PHYSICS) 122 bool IsPhysical { get; set; } // SetStatus(PHYSICS)
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs
index 12d996a..f53a7df 100644
--- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs
+++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs
@@ -103,13 +103,19 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
103 set { GetSOP().Scale = value; } 103 set { GetSOP().Scale = value; }
104 } 104 }
105 105
106 public Quaternion Rotation 106 public Quaternion WorldRotation
107 { 107 {
108 get { throw new System.NotImplementedException(); } 108 get { throw new System.NotImplementedException(); }
109 set { throw new System.NotImplementedException(); } 109 set { throw new System.NotImplementedException(); }
110 } 110 }
111 111
112 public Vector3 Position 112 public Quaternion OffsetRotation
113 {
114 get { throw new System.NotImplementedException(); }
115 set { throw new System.NotImplementedException(); }
116 }
117
118 public Vector3 WorldPosition
113 { 119 {
114 get { return GetSOP().AbsolutePosition; } 120 get { return GetSOP().AbsolutePosition; }
115 set 121 set
@@ -119,6 +125,12 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
119 } 125 }
120 } 126 }
121 127
128 public Vector3 OffsetPosition
129 {
130 get { return GetSOP().OffsetPosition; }
131 set { GetSOP().OffsetPosition = value; }
132 }
133
122 public Vector3 SitTarget 134 public Vector3 SitTarget
123 { 135 {
124 get { throw new System.NotImplementedException(); } 136 get { throw new System.NotImplementedException(); }