Merge branch 'master' into varregion

varregion
Robert Adams 2013-11-04 22:12:57 -08:00
commit c931b16c1f
23 changed files with 7922 additions and 7632 deletions

View File

@ -31,7 +31,6 @@ namespace OpenSim.Framework
{
public string PhysicsEngine { get; set; }
public string MeshEngineName { get; set; }
public string StorageDll { get; set; }
public string ClientstackDll { get; set; }
public string LibrariesXMLFile { get; set; }

View File

@ -338,8 +338,6 @@ namespace OpenSim
config.Set("meshing", "Meshmerizer");
config.Set("physical_prim", true);
config.Set("serverside_object_permissions", true);
config.Set("storage_plugin", "OpenSim.Data.SQLite.dll");
config.Set("storage_connection_string", "URI=file:OpenSim.db,version=3");
config.Set("storage_prim_inventories", true);
config.Set("startup_console_commands_file", String.Empty);
config.Set("shutdown_console_commands_file", String.Empty);
@ -371,7 +369,6 @@ namespace OpenSim
{
m_configSettings.PhysicsEngine = startupConfig.GetString("physics");
m_configSettings.MeshEngineName = startupConfig.GetString("meshing");
m_configSettings.StorageDll = startupConfig.GetString("storage_plugin");
m_configSettings.ClientstackDll
= startupConfig.GetString("clientstack_plugin", "OpenSim.Region.ClientStack.LindenUDP.dll");

View File

@ -49,12 +49,10 @@ using OpenSim.Capabilities.Handlers;
namespace OpenSim.Region.ClientStack.Linden
{
[Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule", Id = "AvatarPickerSearchModule")]
public class AvatarPickerSearchModule : INonSharedRegionModule
{
private static readonly ILog m_log =
LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
// private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
private Scene m_scene;
private IPeople m_People;
@ -134,6 +132,5 @@ namespace OpenSim.Region.ClientStack.Linden
caps.RegisterHandler("AvatarPickerSearch", m_URL);
}
}
}
}

View File

@ -107,7 +107,7 @@ namespace OpenSim.Region.ClientStack.Linden
public void RegisterCaps(UUID agentID, Caps caps)
{
UUID capID = UUID.Random();
// UUID capID = UUID.Random();
//caps.RegisterHandler("GetTexture", new StreamHandler("GET", "/CAPS/" + capID, ProcessGetTexture));
if (m_URL == "localhost")
@ -127,7 +127,6 @@ namespace OpenSim.Region.ClientStack.Linden
{
caps.RegisterHandler("UploadBakedTexture", m_URL);
}
}
}
}

View File

@ -3775,6 +3775,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
// Count this as a resent packet since we are going to requeue all of the updates contained in it
Interlocked.Increment(ref m_udpClient.PacketsResent);
// We're not going to worry about interlock yet since its not currently critical that this total count
// is 100% correct
m_udpServer.PacketsResentCount++;
foreach (EntityUpdate update in updates)
ResendPrimUpdate(update);
}
@ -4335,6 +4339,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
// Count this as a resent packet since we are going to requeue all of the updates contained in it
Interlocked.Increment(ref m_udpClient.PacketsResent);
// We're not going to worry about interlock yet since its not currently critical that this total count
// is 100% correct
m_udpServer.PacketsResentCount++;
foreach (ObjectPropertyUpdate update in updates)
ResendPropertyUpdate(update);
}

View File

@ -145,6 +145,19 @@ namespace OpenSim.Region.ClientStack.LindenUDP
stat => stat.Value = m_udpServer.UdpSends,
StatVerbosity.Debug));
StatsManager.RegisterStat(
new Stat(
"OutgoingPacketsResentCount",
"Number of packets resent because a client did not acknowledge receipt",
"",
"",
"clientstack",
scene.Name,
StatType.Pull,
MeasuresOfInterest.AverageChangeOverTime,
stat => stat.Value = m_udpServer.PacketsResentCount,
StatVerbosity.Debug));
StatsManager.RegisterStat(
new Stat(
"AverageUDPProcessTime",
@ -294,6 +307,16 @@ namespace OpenSim.Region.ClientStack.LindenUDP
public Socket Server { get { return null; } }
/// <summary>
/// Record how many packets have been resent
/// </summary>
internal int PacketsResentCount { get; set; }
/// <summary>
/// Record how many packets have been sent
/// </summary>
internal int PacketsSentCount { get; set; }
/// <summary>
/// Record how many inbound packets could not be recognized as LLUDP packets.
/// </summary>
@ -1214,6 +1237,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
else
{
Interlocked.Increment(ref udpClient.PacketsResent);
// We're not going to worry about interlock yet since its not currently critical that this total count
// is 100% correct
PacketsResentCount++;
}
#endregion Sequence Number Assignment
@ -1221,6 +1248,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
// Stats tracking
Interlocked.Increment(ref udpClient.PacketsSent);
// We're not going to worry about interlock yet since its not currently critical that this total count
// is 100% correct
PacketsSentCount++;
// Put the UDP payload on the wire
AsyncBeginSend(buffer);

View File

@ -31,17 +31,16 @@
using System;
using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Runtime.Serialization;
using System.Runtime.Serialization.Formatters.Binary;
using System.Threading;
using System.Timers;
using log4net;
using Nini.Config;
using Mono.Addins;
using OpenMetaverse;
using OpenSim.Framework;
using OpenSim.Framework.Console;
using OpenSim.Region.Framework.Interfaces;
@ -76,8 +75,6 @@ namespace OpenSim.Region.CoreModules.Asset
private static ulong m_RequestsForInprogress;
private static ulong m_DiskHits;
private static ulong m_MemoryHits;
private static double m_HitRateMemory;
private static double m_HitRateFile;
#if WAIT_ON_INPROGRESS_REQUESTS
private Dictionary<string, ManualResetEvent> m_CurrentlyWriting = new Dictionary<string, ManualResetEvent>();
@ -429,18 +426,9 @@ namespace OpenSim.Region.CoreModules.Asset
if (((m_LogLevel >= 1)) && (m_HitRateDisplay != 0) && (m_Requests % m_HitRateDisplay == 0))
{
m_HitRateFile = (double)m_DiskHits / m_Requests * 100.0;
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: Cache Get :: {0} :: {1}", id, asset == null ? "Miss" : "Hit");
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: File Hit Rate {0}% for {1} requests", m_HitRateFile.ToString("0.00"), m_Requests);
if (m_MemoryCacheEnabled)
{
m_HitRateMemory = (double)m_MemoryHits / m_Requests * 100.0;
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: Memory Hit Rate {0}% for {1} requests", m_HitRateMemory.ToString("0.00"), m_Requests);
}
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: {0} unnessesary requests due to requests for assets that are currently downloading.", m_RequestsForInprogress);
GenerateCacheHitReport().ForEach(l => m_log.InfoFormat("[FLOTSAM ASSET CACHE]: {0}", l));
}
return asset;
@ -807,37 +795,69 @@ namespace OpenSim.Region.CoreModules.Asset
}
}
private List<string> GenerateCacheHitReport()
{
List<string> outputLines = new List<string>();
double fileHitRate = (double)m_DiskHits / m_Requests * 100.0;
outputLines.Add(
string.Format("File Hit Rate: {0}% for {1} requests", fileHitRate.ToString("0.00"), m_Requests));
if (m_MemoryCacheEnabled)
{
double memHitRate = (double)m_MemoryHits / m_Requests * 100.0;
outputLines.Add(
string.Format("Memory Hit Rate: {0}% for {1} requests", memHitRate.ToString("0.00"), m_Requests));
}
outputLines.Add(
string.Format(
"Unnecessary requests due to requests for assets that are currently downloading: {0}",
m_RequestsForInprogress));
return outputLines;
}
#region Console Commands
private void HandleConsoleCommand(string module, string[] cmdparams)
{
ICommandConsole con = MainConsole.Instance;
if (cmdparams.Length >= 2)
{
string cmd = cmdparams[1];
switch (cmd)
{
case "status":
if (m_MemoryCacheEnabled)
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: Memory Cache : {0} assets", m_MemoryCache.Count);
con.OutputFormat("Memory Cache: {0} assets", m_MemoryCache.Count);
else
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: Memory cache disabled");
con.OutputFormat("Memory cache disabled");
if (m_FileCacheEnabled)
{
int fileCount = GetFileCacheCount(m_CacheDirectory);
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: File Cache : {0} assets", fileCount);
foreach (string s in Directory.GetFiles(m_CacheDirectory, "*.fac"))
{
m_log.Info("[FLOTSAM ASSET CACHE]: Deep scans have previously been performed on the following regions:");
string RegionID = s.Remove(0,s.IndexOf("_")).Replace(".fac","");
DateTime RegionDeepScanTMStamp = File.GetLastWriteTime(s);
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: Region: {0}, {1}", RegionID, RegionDeepScanTMStamp.ToString("MM/dd/yyyy hh:mm:ss"));
}
con.OutputFormat("File Cache: {0} assets", fileCount);
}
else
{
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: File cache disabled");
con.Output("File cache disabled");
}
GenerateCacheHitReport().ForEach(l => con.Output(l));
if (m_FileCacheEnabled)
{
con.Output("Deep scans have previously been performed on the following regions:");
foreach (string s in Directory.GetFiles(m_CacheDirectory, "*.fac"))
{
string RegionID = s.Remove(0,s.IndexOf("_")).Replace(".fac","");
DateTime RegionDeepScanTMStamp = File.GetLastWriteTime(s);
con.OutputFormat("Region: {0}, {1}", RegionID, RegionDeepScanTMStamp.ToString("MM/dd/yyyy hh:mm:ss"));
}
}
break;
@ -845,7 +865,7 @@ namespace OpenSim.Region.CoreModules.Asset
case "clear":
if (cmdparams.Length < 2)
{
m_log.Warn("[FLOTSAM ASSET CACHE]: Usage is fcache clear [file] [memory]");
con.Output("Usage is fcache clear [file] [memory]");
break;
}
@ -869,11 +889,11 @@ namespace OpenSim.Region.CoreModules.Asset
if (m_MemoryCacheEnabled)
{
m_MemoryCache.Clear();
m_log.Info("[FLOTSAM ASSET CACHE]: Memory cache cleared.");
con.Output("Memory cache cleared.");
}
else
{
m_log.Info("[FLOTSAM ASSET CACHE]: Memory cache not enabled.");
con.Output("Memory cache not enabled.");
}
}
@ -882,24 +902,22 @@ namespace OpenSim.Region.CoreModules.Asset
if (m_FileCacheEnabled)
{
ClearFileCache();
m_log.Info("[FLOTSAM ASSET CACHE]: File cache cleared.");
con.Output("File cache cleared.");
}
else
{
m_log.Info("[FLOTSAM ASSET CACHE]: File cache not enabled.");
con.Output("File cache not enabled.");
}
}
break;
case "assets":
m_log.Info("[FLOTSAM ASSET CACHE]: Ensuring assets are cached for all scenes.");
con.Output("Ensuring assets are cached for all scenes.");
Util.FireAndForget(delegate {
int assetReferenceTotal = TouchAllSceneAssets(true);
m_log.InfoFormat(
"[FLOTSAM ASSET CACHE]: Completed check with {0} assets.",
assetReferenceTotal);
con.OutputFormat("Completed check with {0} assets.", assetReferenceTotal);
});
break;
@ -907,7 +925,7 @@ namespace OpenSim.Region.CoreModules.Asset
case "expire":
if (cmdparams.Length < 3)
{
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: Invalid parameters for Expire, please specify a valid date & time", cmd);
con.OutputFormat("Invalid parameters for Expire, please specify a valid date & time", cmd);
break;
}
@ -925,28 +943,27 @@ namespace OpenSim.Region.CoreModules.Asset
if (!DateTime.TryParse(s_expirationDate, out expirationDate))
{
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: {0} is not a valid date & time", cmd);
con.OutputFormat("{0} is not a valid date & time", cmd);
break;
}
if (m_FileCacheEnabled)
CleanExpiredFiles(m_CacheDirectory, expirationDate);
else
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: File cache not active, not clearing.");
con.OutputFormat("File cache not active, not clearing.");
break;
default:
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: Unknown command {0}", cmd);
con.OutputFormat("Unknown command {0}", cmd);
break;
}
}
else if (cmdparams.Length == 1)
{
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: fcache status - Display cache status");
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: fcache clearmem - Remove all assets cached in memory");
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: fcache clearfile - Remove all assets cached on disk");
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: fcache cachescenes - Attempt a deep cache of all assets in all scenes");
m_log.InfoFormat("[FLOTSAM ASSET CACHE]: fcache <datetime> - Purge assets older then the specified date & time");
con.Output("fcache assets - Attempt a deep cache of all assets in all scenes");
con.Output("fcache expire <datetime> - Purge assets older then the specified date & time");
con.Output("fcache clear [file] [memory] - Remove cached assets");
con.Output("fcache status - Display cache status");
}
}

View File

@ -629,10 +629,11 @@ namespace OpenSim.Region.Physics.Meshing
try
{
OpenMetaverse.Imaging.ManagedImage unusedData;
OpenMetaverse.Imaging.OpenJPEG.DecodeToImage(primShape.SculptData, out unusedData, out idata);
OpenMetaverse.Imaging.ManagedImage managedImage;
if (idata == null)
OpenMetaverse.Imaging.OpenJPEG.DecodeToImage(primShape.SculptData, out managedImage);
if (managedImage == null)
{
// In some cases it seems that the decode can return a null bitmap without throwing
// an exception
@ -641,9 +642,12 @@ namespace OpenSim.Region.Physics.Meshing
return false;
}
unusedData = null;
if ((managedImage.Channels & OpenMetaverse.Imaging.ManagedImage.ImageChannels.Alpha) != 0)
managedImage.ConvertChannels(managedImage.Channels & ~OpenMetaverse.Imaging.ManagedImage.ImageChannels.Alpha);
//idata = CSJ2K.J2kImage.FromBytes(primShape.SculptData);
Bitmap imgData = OpenMetaverse.Imaging.LoadTGAClass.LoadTGA(new MemoryStream(managedImage.ExportTGA()));
idata = (Image)imgData;
managedImage = null;
if (cacheSculptMaps)
{

View File

@ -6237,7 +6237,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
PSYS_SRC_TARGET_KEY = 20,
PSYS_SRC_OMEGA = 21,
PSYS_SRC_ANGLE_BEGIN = 22,
PSYS_SRC_ANGLE_END = 23
PSYS_SRC_ANGLE_END = 23,
PSYS_PART_BLEND_FUNC_SOURCE = 24,
PSYS_PART_BLEND_FUNC_DEST = 25,
PSYS_PART_START_GLOW = 26,
PSYS_PART_END_GLOW = 27
}
internal Primitive.ParticleSystem.ParticleDataFlags ConvertUINTtoFlags(uint flags)

View File

@ -106,6 +106,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
public const int PSYS_PART_TARGET_POS_MASK = 64;
public const int PSYS_PART_TARGET_LINEAR_MASK = 128;
public const int PSYS_PART_EMISSIVE_MASK = 256;
public const int PSYS_PART_RIBBON_MASK = 1024;
public const int PSYS_PART_FLAGS = 0;
public const int PSYS_PART_START_COLOR = 1;
public const int PSYS_PART_START_ALPHA = 2;
@ -129,6 +130,18 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
public const int PSYS_SRC_OMEGA = 21;
public const int PSYS_SRC_ANGLE_BEGIN = 22;
public const int PSYS_SRC_ANGLE_END = 23;
public const int PSYS_PART_BLEND_FUNC_SOURCE = 24;
public const int PSYS_PART_BLEND_FUNC_DEST = 25;
public const int PSYS_PART_START_GLOW = 26;
public const int PSYS_PART_END_GLOW = 27;
public const int PSYS_PART_BF_ONE = 0;
public const int PSYS_PART_BF_ZERO = 1;
public const int PSYS_PART_BF_DEST_COLOR = 2;
public const int PSYS_PART_BF_SOURCE_COLOR = 3;
public const int PSYS_PART_BF_ONE_MINUS_DEST_COLOR = 4;
public const int PSYS_PART_BF_ONE_MINUS_SOURCE_COLOR = 5;
public const int PSYS_PART_BF_SOURCE_ALPHA = 7;
public const int PSYS_PART_BF_ONE_MINUS_SOURCE_ALPHA = 9;
public const int PSYS_SRC_PATTERN_DROP = 1;
public const int PSYS_SRC_PATTERN_EXPLODE = 2;
public const int PSYS_SRC_PATTERN_ANGLE = 4;

View File

@ -610,6 +610,7 @@ namespace SecondLife
results = CScodeProvider.CompileAssemblyFromSource(
parameters, Script);
}
// Deal with an occasional segv in the compiler.
// Rarely, if ever, occurs twice in succession.
// Line # == 0 and no file name are indications that
@ -647,15 +648,19 @@ namespace SecondLife
"language type \"" + lang.ToString() + "\"");
}
// Check result
// Go through errors
// foreach (Type type in results.CompiledAssembly.GetTypes())
// {
// foreach (MethodInfo method in type.GetMethods(BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.Static))
// {
// m_log.DebugFormat("[COMPILER]: {0}.{1}", type.FullName, method.Name);
// }
// }
//
// WARNINGS AND ERRORS
//
bool hadErrors = false;
string errtext = String.Empty;
if (results.Errors.Count > 0)
{
foreach (CompilerError CompErr in results.Errors)

View File

@ -27,12 +27,16 @@
using System;
using System.Collections.Generic;
using System.Reflection;
using log4net;
using Tools;
namespace OpenSim.Region.ScriptEngine.Shared.CodeTools
{
public class LSL2CSCodeTransformer
{
// private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
private SYMBOL m_astRoot = null;
private static Dictionary<string, string> m_datatypeLSL2OpenSim = null;
@ -78,6 +82,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools
/// <param name="s">The current node to transform.</param>
private void TransformNode(SYMBOL s)
{
// m_log.DebugFormat("[LSL2CSCODETRANSFORMER]: Tranforming node {0}", s);
// make sure to put type lower in the inheritance hierarchy first
// ie: since IdentConstant and StringConstant inherit from Constant,
// put IdentConstant and StringConstant before Constant
@ -103,10 +109,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools
// We need to check for that here.
if (null != s.kids[i])
{
// m_log.Debug("[LSL2CSCODETRANSFORMER]: Moving down level");
if (!(s is Assignment || s is ArgumentDeclarationList) && s.kids[i] is Declaration)
AddImplicitInitialization(s, i);
TransformNode((SYMBOL) s.kids[i]);
// m_log.Debug("[LSL2CSCODETRANSFORMER]: Moving up level");
}
}
}

View File

@ -762,6 +762,7 @@ default
public void TestIfStatement()
{
TestHelpers.InMethod();
// TestHelpers.EnableLogging();
string input = @"// let's test if statements

File diff suppressed because it is too large Load Diff

View File

@ -114,29 +114,32 @@ namespace OpenSim.Services.Connectors
}
else if (replyData.ContainsKey("Result") && (replyData["Result"].ToString().ToLower() == "failure"))
{
m_log.DebugFormat("[MAP IMAGE CONNECTOR]: Registration failed: {0}", replyData["Message"].ToString());
reason = replyData["Message"].ToString();
reason = string.Format("Map post to {0} failed: {1}", uri, replyData["Message"].ToString());
m_log.WarnFormat("[MAP IMAGE CONNECTOR]: {0}", reason);
return false;
}
else if (!replyData.ContainsKey("Result"))
{
m_log.DebugFormat("[MAP IMAGE CONNECTOR]: reply data does not contain result field");
reason = string.Format("Reply data from {0} does not contain result field", uri);
m_log.WarnFormat("[MAP IMAGE CONNECTOR]: {0}", reason);
}
else
{
m_log.DebugFormat("[MAP IMAGE CONNECTOR]: unexpected result {0}", replyData["Result"].ToString());
reason = "Unexpected result " + replyData["Result"].ToString();
reason = string.Format("Unexpected result {0} from {1}" + replyData["Result"].ToString(), uri);
m_log.WarnFormat("[MAP IMAGE CONNECTOR]: {0}", reason);
}
}
else
{
m_log.DebugFormat("[MAP IMAGE CONNECTOR]: Map post received null reply");
reason = string.Format("Map post received null reply from {0}", uri);
m_log.WarnFormat("[MAP IMAGE CONNECTOR]: {0}", reason);
}
}
catch (Exception e)
{
m_log.DebugFormat("[MAP IMAGE CONNECTOR]: Exception when contacting map server at {0}: {1}", uri, e.Message);
reason = string.Format("Exception when posting to map server at {0}: {1}", uri, e.Message);
m_log.WarnFormat("[MAP IMAGE CONNECTOR]: {0}", reason);
}
finally
{

View File

@ -240,8 +240,6 @@ namespace OpenSim.Tools.Configger
config.Set("meshing", "Meshmerizer");
config.Set("physical_prim", true);
config.Set("serverside_object_permissions", true);
config.Set("storage_plugin", "OpenSim.Data.SQLite.dll");
config.Set("storage_connection_string", "URI=file:OpenSim.db,version=3");
config.Set("storage_prim_inventories", true);
config.Set("startup_console_commands_file", String.Empty);
config.Set("shutdown_console_commands_file", String.Empty);
@ -253,6 +251,5 @@ namespace OpenSim.Tools.Configger
return defaultConfig;
}
}
}

View File

@ -166,7 +166,7 @@ namespace pCampBot
{
ConnectionState = ConnectionState.Disconnected;
Random = new Random(Environment.TickCount);// We do stuff randomly here
Random = new Random(bm.Rng.Next());
FirstName = firstName;
LastName = lastName;
Name = string.Format("{0} {1}", FirstName, LastName);

View File

@ -176,57 +176,57 @@ namespace pCampBot
}
m_console.Commands.AddCommand(
"bot", false, "shutdown", "shutdown", "Shutdown bots and exit", HandleShutdown);
"Bots", false, "shutdown", "shutdown", "Shutdown bots and exit", HandleShutdown);
m_console.Commands.AddCommand(
"bot", false, "quit", "quit", "Shutdown bots and exit", HandleShutdown);
"Bots", false, "quit", "quit", "Shutdown bots and exit", HandleShutdown);
m_console.Commands.AddCommand(
"bot", false, "connect", "connect [<n>]", "Connect bots",
"Bots", false, "connect", "connect [<n>]", "Connect bots",
"If an <n> is given, then the first <n> disconnected bots by postfix number are connected.\n"
+ "If no <n> is given, then all currently disconnected bots are connected.",
HandleConnect);
m_console.Commands.AddCommand(
"bot", false, "disconnect", "disconnect [<n>]", "Disconnect bots",
"Bots", false, "disconnect", "disconnect [<n>]", "Disconnect bots",
"Disconnecting bots will interupt any bot connection process, including connection on startup.\n"
+ "If an <n> is given, then the last <n> connected bots by postfix number are disconnected.\n"
+ "If no <n> is given, then all currently connected bots are disconnected.",
HandleDisconnect);
m_console.Commands.AddCommand(
"bot", false, "add behaviour", "add behaviour <abbreviated-name> [<bot-number>]",
"Bots", false, "add behaviour", "add behaviour <abbreviated-name> [<bot-number>]",
"Add a behaviour to a bot",
"If no bot number is specified then behaviour is added to all bots.\n"
+ "Can be performed on connected or disconnected bots.",
HandleAddBehaviour);
m_console.Commands.AddCommand(
"bot", false, "remove behaviour", "remove behaviour <abbreviated-name> [<bot-number>]",
"Bots", false, "remove behaviour", "remove behaviour <abbreviated-name> [<bot-number>]",
"Remove a behaviour from a bot",
"If no bot number is specified then behaviour is added to all bots.\n"
+ "Can be performed on connected or disconnected bots.",
HandleRemoveBehaviour);
m_console.Commands.AddCommand(
"bot", false, "sit", "sit", "Sit all bots on the ground.",
"Bots", false, "sit", "sit", "Sit all bots on the ground.",
HandleSit);
m_console.Commands.AddCommand(
"bot", false, "stand", "stand", "Stand all bots.",
"Bots", false, "stand", "stand", "Stand all bots.",
HandleStand);
m_console.Commands.AddCommand(
"bot", false, "set bots", "set bots <key> <value>", "Set a setting for all bots.", HandleSetBots);
"Bots", false, "set bots", "set bots <key> <value>", "Set a setting for all bots.", HandleSetBots);
m_console.Commands.AddCommand(
"bot", false, "show regions", "show regions", "Show regions known to bots", HandleShowRegions);
"Bots", false, "show regions", "show regions", "Show regions known to bots", HandleShowRegions);
m_console.Commands.AddCommand(
"bot", false, "show bots", "show bots", "Shows the status of all bots", HandleShowBotsStatus);
"Bots", false, "show bots", "show bots", "Shows the status of all bots", HandleShowBotsStatus);
m_console.Commands.AddCommand(
"bot", false, "show bot", "show bot <bot-number>",
"Bots", false, "show bot", "show bot <bot-number>",
"Shows the detailed status and settings of a particular bot.", HandleShowBotStatus);
m_bots = new List<Bot>();

View File

@ -151,17 +151,17 @@ namespace pCampBot
// worn to the folder MyAppearance/FirstName_LastName, and the load it.
Console.WriteLine(
"usage: pCampBot <-loginuri loginuri> [OPTIONS]\n"
"Usage: pCampBot -loginuri <loginuri> -firstname <first-name> -lastname <last-name> -password <password> [OPTIONS]\n"
+ "Spawns a set of bots to test an OpenSim region\n\n"
+ " -l, -loginuri loginuri for grid/standalone (required)\n"
+ " -s, -start start location for bots (optional). Can be \"last\", \"home\" or a specific location with or without co-ords (e.g. \"region1\" or \"region2/50/30/90\"\n"
+ " -s, -start start location for bots (default: last) (optional). Can be \"last\", \"home\" or a specific location with or without co-ords (e.g. \"region1\" or \"region2/50/30/90\"\n"
+ " -firstname first name for the bots (required)\n"
+ " -lastname lastname for the bots (required). Each lastname will have _<bot-number> appended, e.g. Ima Bot_0\n"
+ " -password password for the bots (required)\n"
+ " -n, -botcount number of bots to start (default: 1) (optional)\n"
+ " -f, -from starting number for login bot names, e.g. 25 will login Ima Bot_25, Ima Bot_26, etc. (default: 0) (optional)\n"
+ " -f, -from starting number for login bot names, e.g. 25 will login Ima Bot_25, Ima Bot_26, etc. (default: 0) (optional)\n"
+ " -c, -connect connect all bots at startup (optional)\n"
+ " -b, behaviours behaviours for bots. Comma separated, e.g. p,g. Default is p (required)\n"
+ " -b, behaviours behaviours for bots. Comma separated, e.g. p,g (default: p) (optional)\n"
+ " current options are:\n"
+ " p (physics - bots constantly move and jump around)\n"
+ " g (grab - bots randomly click prims whether set clickable or not)\n"

Binary file not shown.

Binary file not shown.

Binary file not shown.