aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2013-09-03 19:41:12 +0100
committerJustin Clark-Casey (justincc)2013-09-03 19:41:12 +0100
commit76bd2e2d727a15e5d3bc9045bdef6faaeca4a08f (patch)
tree62cbb335ba86afce165fdf5bc5e73805c3b3ed20 /OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs
parentAdd Close() method to IBehaviour to allow behaviours to cleanup when removed ... (diff)
downloadopensim-SC-76bd2e2d727a15e5d3bc9045bdef6faaeca4a08f.zip
opensim-SC-76bd2e2d727a15e5d3bc9045bdef6faaeca4a08f.tar.gz
opensim-SC-76bd2e2d727a15e5d3bc9045bdef6faaeca4a08f.tar.bz2
opensim-SC-76bd2e2d727a15e5d3bc9045bdef6faaeca4a08f.tar.xz
Consistently give responsibility for thread sleeping to behaviours rather than controlling from the main action loop
This is to avoid excessive and inconsistent delays between behaviours that currently need to embed sleeps in other actions (e.g. physics) and other behaviours. Might need a more sophisticated approach in the long term.
Diffstat (limited to 'OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs')
-rw-r--r--OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs3
1 files changed, 3 insertions, 0 deletions
diff --git a/OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs b/OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs
index 6acc27d..59f6244 100644
--- a/OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs
+++ b/OpenSim/Tools/pCampBot/Behaviours/GrabbingBehaviour.cs
@@ -29,6 +29,7 @@ using OpenMetaverse;
29using System; 29using System;
30using System.Collections.Generic; 30using System.Collections.Generic;
31using System.Linq; 31using System.Linq;
32using System.Threading;
32using pCampBot.Interfaces; 33using pCampBot.Interfaces;
33 34
34namespace pCampBot 35namespace pCampBot
@@ -60,6 +61,8 @@ namespace pCampBot
60 Bot.Client.Self.Grab(prim.LocalID); 61 Bot.Client.Self.Grab(prim.LocalID);
61 Bot.Client.Self.GrabUpdate(prim.ID, Vector3.Zero); 62 Bot.Client.Self.GrabUpdate(prim.ID, Vector3.Zero);
62 Bot.Client.Self.DeGrab(prim.LocalID); 63 Bot.Client.Self.DeGrab(prim.LocalID);
64
65 Thread.Sleep(1000);
63 } 66 }
64 } 67 }
65} \ No newline at end of file 68} \ No newline at end of file