diff options
author | UbitUmarov | 2015-11-16 23:21:58 +0000 |
---|---|---|
committer | UbitUmarov | 2015-11-16 23:21:58 +0000 |
commit | 9c5646a1ba92a2a2cd1ab546a622bf2186eb8219 (patch) | |
tree | 1d21f59ee1bf449582cdb8688dff834ad4879fe3 /OpenSim/Region/ScriptEngine | |
parent | work around some 'tests' errors: fix math (diff) | |
download | opensim-SC_OLD-9c5646a1ba92a2a2cd1ab546a622bf2186eb8219.zip opensim-SC_OLD-9c5646a1ba92a2a2cd1ab546a622bf2186eb8219.tar.gz opensim-SC_OLD-9c5646a1ba92a2a2cd1ab546a622bf2186eb8219.tar.bz2 opensim-SC_OLD-9c5646a1ba92a2a2cd1ab546a622bf2186eb8219.tar.xz |
work around some 'tests' errors: dont use references to objects that may have been deleted
Diffstat (limited to 'OpenSim/Region/ScriptEngine')
-rw-r--r-- | OpenSim/Region/ScriptEngine/XEngine/Tests/XEngineCrossingTests.cs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/OpenSim/Region/ScriptEngine/XEngine/Tests/XEngineCrossingTests.cs b/OpenSim/Region/ScriptEngine/XEngine/Tests/XEngineCrossingTests.cs index 587695f..2bf8d22 100644 --- a/OpenSim/Region/ScriptEngine/XEngine/Tests/XEngineCrossingTests.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/Tests/XEngineCrossingTests.cs | |||
@@ -111,10 +111,13 @@ namespace OpenSim.Region.ScriptEngine.XEngine.Tests | |||
111 | SceneObjectGroup soSceneA = SceneHelpers.AddSceneObject(sceneA, 1, userId, "so1-", sceneObjectIdTail); | 111 | SceneObjectGroup soSceneA = SceneHelpers.AddSceneObject(sceneA, 1, userId, "so1-", sceneObjectIdTail); |
112 | soSceneA.AbsolutePosition = new Vector3(128, 10, 20); | 112 | soSceneA.AbsolutePosition = new Vector3(128, 10, 20); |
113 | 113 | ||
114 | string soSceneAName = soSceneA.Name; | ||
115 | string scriptItemSceneAName = "script1"; | ||
116 | |||
114 | // CREATE SCRIPT TODO | 117 | // CREATE SCRIPT TODO |
115 | InventoryItemBase scriptItemSceneA = new InventoryItemBase(); | 118 | InventoryItemBase scriptItemSceneA = new InventoryItemBase(); |
116 | // itemTemplate.ID = itemId; | 119 | // itemTemplate.ID = itemId; |
117 | scriptItemSceneA.Name = "script1"; | 120 | scriptItemSceneA.Name = scriptItemSceneAName; |
118 | scriptItemSceneA.Folder = soSceneA.UUID; | 121 | scriptItemSceneA.Folder = soSceneA.UUID; |
119 | scriptItemSceneA.InvType = (int)InventoryType.LSL; | 122 | scriptItemSceneA.InvType = (int)InventoryType.LSL; |
120 | 123 | ||
@@ -174,8 +177,8 @@ default | |||
174 | 177 | ||
175 | // TEST sending event to moved prim and output | 178 | // TEST sending event to moved prim and output |
176 | { | 179 | { |
177 | SceneObjectGroup soSceneB = sceneB.GetSceneObjectGroup(soSceneA.Name); | 180 | SceneObjectGroup soSceneB = sceneB.GetSceneObjectGroup(soSceneAName); |
178 | TaskInventoryItem scriptItemSceneB = soSceneB.RootPart.Inventory.GetInventoryItem(scriptItemSceneA.Name); | 181 | TaskInventoryItem scriptItemSceneB = soSceneB.RootPart.Inventory.GetInventoryItem(scriptItemSceneAName); |
179 | 182 | ||
180 | // XXX: Should not be doing this so directly. Should call some variant of EventManager.touch() instead. | 183 | // XXX: Should not be doing this so directly. Should call some variant of EventManager.touch() instead. |
181 | DetectParams[] det = new DetectParams[1]; | 184 | DetectParams[] det = new DetectParams[1]; |