diff options
author | Justin Clark-Casey (justincc) | 2011-11-23 21:19:10 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2011-11-23 21:19:10 +0000 |
commit | e9f2a9bddbb47ac8c80aeccea0022ad534cbd552 (patch) | |
tree | 5d74bb33a073630a45c4dcf3654c91bc1f5093cc /OpenSim/Tools/pCampBot/Bot.cs | |
parent | Merge branch 'master' of ssh://opensimulator.org/var/git/opensim (diff) | |
download | opensim-SC-e9f2a9bddbb47ac8c80aeccea0022ad534cbd552.zip opensim-SC-e9f2a9bddbb47ac8c80aeccea0022ad534cbd552.tar.gz opensim-SC-e9f2a9bddbb47ac8c80aeccea0022ad534cbd552.tar.bz2 opensim-SC-e9f2a9bddbb47ac8c80aeccea0022ad534cbd552.tar.xz |
get pCampBot to extract nearby and store nearby region information
Diffstat (limited to 'OpenSim/Tools/pCampBot/Bot.cs')
-rw-r--r-- | OpenSim/Tools/pCampBot/Bot.cs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/OpenSim/Tools/pCampBot/Bot.cs b/OpenSim/Tools/pCampBot/Bot.cs index 7f941a4..7c16bf4 100644 --- a/OpenSim/Tools/pCampBot/Bot.cs +++ b/OpenSim/Tools/pCampBot/Bot.cs | |||
@@ -218,7 +218,19 @@ namespace pCampBot | |||
218 | { | 218 | { |
219 | MakeDefaultAppearance(wear); | 219 | MakeDefaultAppearance(wear); |
220 | } | 220 | } |
221 | |||
221 | Client.Self.Jump(true); | 222 | Client.Self.Jump(true); |
223 | |||
224 | // Extract nearby region information. | ||
225 | Client.Grid.GridRegion += BotManager.Grid_GridRegion; | ||
226 | uint xUint, yUint; | ||
227 | Utils.LongToUInts(Client.Network.CurrentSim.Handle, out xUint, out yUint); | ||
228 | ushort minX, minY, maxX, maxY; | ||
229 | minX = (ushort)Math.Min(0, xUint - 5); | ||
230 | minY = (ushort)Math.Min(0, yUint - 5); | ||
231 | maxX = (ushort)(xUint + 5); | ||
232 | maxY = (ushort)(yUint + 5); | ||
233 | Client.Grid.RequestMapBlocks(GridLayerType.Terrain, minX, minY, maxX, maxY, false); | ||
222 | } | 234 | } |
223 | else | 235 | else |
224 | { | 236 | { |