mirror of
https://github.com/opensim/opensim.git
synced 2026-08-09 18:55:58 +08:00
remove some more useless NULL arguments
This commit is contained in:
@@ -114,20 +114,20 @@ namespace OpenSim.Region.OptionalModules.Agent.TextureSender
|
||||
|
||||
if (!UUID.TryParse(rawAssetId, out assetId))
|
||||
{
|
||||
MainConsole.Instance.Output("ERROR: {0} is not a valid ID format", null, rawAssetId);
|
||||
MainConsole.Instance.Output("ERROR: {0} is not a valid ID format", rawAssetId);
|
||||
return;
|
||||
}
|
||||
|
||||
AssetBase asset = m_scene.AssetService.Get(assetId.ToString());
|
||||
if (asset == null)
|
||||
{
|
||||
MainConsole.Instance.Output("ERROR: No asset found with ID {0}", null, assetId);
|
||||
MainConsole.Instance.Output("ERROR: No asset found with ID {0}", assetId);
|
||||
return;
|
||||
}
|
||||
|
||||
if (asset.Type != (sbyte)AssetType.Texture)
|
||||
{
|
||||
MainConsole.Instance.Output("ERROR: Asset {0} is not a texture type", null, assetId);
|
||||
MainConsole.Instance.Output("ERROR: Asset {0} is not a texture type", assetId);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -144,12 +144,11 @@ namespace OpenSim.Region.OptionalModules.Agent.TextureSender
|
||||
{
|
||||
MainConsole.Instance.Output(
|
||||
"Successfully decoded asset {0} with {1} layers and {2} components",
|
||||
null,
|
||||
assetId, layers.Length, components);
|
||||
}
|
||||
else
|
||||
{
|
||||
MainConsole.Instance.Output("Decode of asset {0} failed", null, assetId);
|
||||
MainConsole.Instance.Output("Decode of asset {0} failed", assetId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -115,14 +115,14 @@ namespace OpenSim.Region.OptionalModules.Asset
|
||||
|
||||
if (!UUID.TryParse(rawAssetId, out assetId))
|
||||
{
|
||||
MainConsole.Instance.Output("ERROR: {0} is not a valid ID format", null, rawAssetId);
|
||||
MainConsole.Instance.Output("ERROR: {0} is not a valid ID format", rawAssetId);
|
||||
return;
|
||||
}
|
||||
|
||||
AssetBase asset = m_scene.AssetService.Get(assetId.ToString());
|
||||
if (asset == null)
|
||||
{
|
||||
MainConsole.Instance.Output("ERROR: No asset found with ID {0}", null, assetId);
|
||||
MainConsole.Instance.Output("ERROR: No asset found with ID {0}", assetId);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -139,7 +139,7 @@ namespace OpenSim.Region.OptionalModules.Asset
|
||||
}
|
||||
}
|
||||
|
||||
MainConsole.Instance.Output("Asset dumped to file {0}", null, fileName);
|
||||
MainConsole.Instance.Output("Asset dumped to file {0}", fileName);
|
||||
}
|
||||
|
||||
void HandleShowAsset(string module, string[] args)
|
||||
@@ -160,13 +160,13 @@ namespace OpenSim.Region.OptionalModules.Asset
|
||||
|
||||
int i;
|
||||
|
||||
MainConsole.Instance.Output("Name: {0}", null, asset.Name);
|
||||
MainConsole.Instance.Output("Description: {0}", null, asset.Description);
|
||||
MainConsole.Instance.Output("Type: {0} (type number = {1})", null, (AssetType)asset.Type, asset.Type);
|
||||
MainConsole.Instance.Output("Content-type: {0}", null, asset.Metadata.ContentType);
|
||||
MainConsole.Instance.Output("Size: {0} bytes", null, asset.Data.Length);
|
||||
MainConsole.Instance.Output("Temporary: {0}", null, asset.Temporary ? "yes" : "no");
|
||||
MainConsole.Instance.Output("Flags: {0}", null, asset.Metadata.Flags);
|
||||
MainConsole.Instance.Output("Name: {0}", asset.Name);
|
||||
MainConsole.Instance.Output("Description: {0}", asset.Description);
|
||||
MainConsole.Instance.Output("Type: {0} (type number = {1})", (AssetType)asset.Type, asset.Type);
|
||||
MainConsole.Instance.Output("Content-type: {0}", asset.Metadata.ContentType);
|
||||
MainConsole.Instance.Output("Size: {0} bytes", asset.Data.Length);
|
||||
MainConsole.Instance.Output("Temporary: {0}", asset.Temporary ? "yes" : "no");
|
||||
MainConsole.Instance.Output("Flags: {0}", asset.Metadata.Flags);
|
||||
|
||||
for (i = 0 ; i < 5 ; i++)
|
||||
{
|
||||
|
||||
@@ -180,7 +180,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Appearance
|
||||
{
|
||||
MainConsole.Instance.Output(
|
||||
"Sending appearance information for {0} to all other avatars in {1}",
|
||||
null,
|
||||
sp.Name, scene.RegionInfo.RegionName);
|
||||
|
||||
scene.AvatarFactory.SendAppearance(sp.UUID);
|
||||
@@ -193,7 +192,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Appearance
|
||||
{
|
||||
MainConsole.Instance.Output(
|
||||
"Sending appearance information for {0} to all other avatars in {1}",
|
||||
null,
|
||||
sp.Name, scene.RegionInfo.RegionName);
|
||||
|
||||
scene.AvatarFactory.SendAppearance(sp.UUID);
|
||||
@@ -240,7 +238,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Appearance
|
||||
{
|
||||
bool bakedTextureValid = scene.AvatarFactory.ValidateBakedTextureCache(sp);
|
||||
MainConsole.Instance.Output(
|
||||
"{0} baked appearance texture is {1}", null, sp.Name, bakedTextureValid ? "OK" : "incomplete");
|
||||
"{0} baked appearance texture is {1}", sp.Name, bakedTextureValid ? "OK" : "incomplete");
|
||||
}
|
||||
);
|
||||
}
|
||||
@@ -271,12 +269,10 @@ namespace OpenSim.Region.OptionalModules.Avatar.Appearance
|
||||
if (rebakesRequested > 0)
|
||||
MainConsole.Instance.Output(
|
||||
"Requesting rebake of {0} uploaded textures for {1} in {2}",
|
||||
null,
|
||||
rebakesRequested, sp.Name, scene.RegionInfo.RegionName);
|
||||
else
|
||||
MainConsole.Instance.Output(
|
||||
"No texture IDs available for rebake request for {0} in {1}",
|
||||
null,
|
||||
sp.Name, scene.RegionInfo.RegionName);
|
||||
}
|
||||
}
|
||||
@@ -320,7 +316,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Appearance
|
||||
{
|
||||
MainConsole.Instance.Output(
|
||||
"{0} matched {1}",
|
||||
null,
|
||||
rawUuid,
|
||||
string.Join(", ", matchedAvatars.ToList().ConvertAll<string>(sp => sp.Name).ToArray()));
|
||||
}
|
||||
|
||||
@@ -136,7 +136,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Friends
|
||||
|
||||
if (userId == UUID.Zero)
|
||||
{
|
||||
MainConsole.Instance.Output("No such user as {0} {1}", null, firstName, lastName);
|
||||
MainConsole.Instance.Output("No such user as {0} {1}", firstName, lastName);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -146,7 +146,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Friends
|
||||
{
|
||||
if (!m_friendsModule.AreFriendsCached(userId))
|
||||
{
|
||||
MainConsole.Instance.Output("No friends cached on this simulator for {0} {1}", null, firstName, lastName);
|
||||
MainConsole.Instance.Output("No friends cached on this simulator for {0} {1}", firstName, lastName);
|
||||
return;
|
||||
}
|
||||
else
|
||||
@@ -162,10 +162,10 @@ namespace OpenSim.Region.OptionalModules.Avatar.Friends
|
||||
friends = ((FriendsModule)m_friendsModule).FriendsService.GetFriends(userId);
|
||||
}
|
||||
|
||||
MainConsole.Instance.Output("Friends for {0} {1} {2}:", null, firstName, lastName, userId);
|
||||
MainConsole.Instance.Output("Friends for {0} {1} {2}:", firstName, lastName, userId);
|
||||
|
||||
MainConsole.Instance.Output(
|
||||
"{0,-36} {1,-36} {2,-7} {3,7} {4,10}", null, "UUID", "Name", "Status", "MyFlags", "TheirFlags");
|
||||
"{0,-36} {1,-36} {2,-7} {3,7} {4,10}", "UUID", "Name", "Status", "MyFlags", "TheirFlags");
|
||||
|
||||
foreach (FriendInfo friend in friends)
|
||||
{
|
||||
@@ -193,7 +193,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Friends
|
||||
|
||||
MainConsole.Instance.Output(
|
||||
"{0,-36} {1,-36} {2,-7} {3,-7} {4,-10}",
|
||||
null,
|
||||
friend.Friend, friendName, onlineText, friend.MyFlags, friend.TheirFlags);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -144,7 +144,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.SitStand
|
||||
{
|
||||
MainConsole.Instance.Output(
|
||||
"Sitting {0} on {1} {2} in {3}",
|
||||
null,
|
||||
sp.Name, sitPart.ParentGroup.Name, sitPart.ParentGroup.UUID, m_scene.Name);
|
||||
|
||||
sp.HandleAgentRequestSit(sp.ControllingClient, sp.UUID, sitPart.UUID, Vector3.Zero);
|
||||
@@ -154,7 +153,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.SitStand
|
||||
{
|
||||
MainConsole.Instance.Output(
|
||||
"Could not find any unoccupied set seat on which to sit {0} in {1}. Aborting",
|
||||
null,
|
||||
sp.Name, m_scene.Name);
|
||||
|
||||
break;
|
||||
@@ -179,7 +177,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.SitStand
|
||||
{
|
||||
if (sp.SitGround || sp.IsSatOnObject)
|
||||
{
|
||||
MainConsole.Instance.Output("Standing {0} in {1}", null, sp.Name, m_scene.Name);
|
||||
MainConsole.Instance.Output("Standing {0} in {1}", sp.Name, m_scene.Name);
|
||||
sp.StandUp();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -256,13 +256,13 @@ namespace OpenSim.Region.OptionalModules.PhysicsParameters
|
||||
private void WriteOut(string msg, params object[] args)
|
||||
{
|
||||
// m_log.InfoFormat(msg, args);
|
||||
MainConsole.Instance.Output(msg, null, args);
|
||||
MainConsole.Instance.Output(msg, args);
|
||||
}
|
||||
|
||||
private void WriteError(string msg, params object[] args)
|
||||
{
|
||||
// m_log.ErrorFormat(msg, args);
|
||||
MainConsole.Instance.Output(msg, null, args);
|
||||
MainConsole.Instance.Output(msg, args);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -186,7 +186,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.JsonStore
|
||||
return;
|
||||
|
||||
JsonStoreStats stats = m_store.GetStoreStats();
|
||||
MainConsole.Instance.Output("{0}\t{1}", null, m_scene.RegionInfo.RegionName, stats.StoreCount);
|
||||
MainConsole.Instance.Output("{0}\t{1}", m_scene.RegionInfo.RegionName, stats.StoreCount);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -109,7 +109,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
|
||||
// This should always show up to the user but should not trigger warn/errors as these messages are
|
||||
// expected and are not simulator problems. Ideally, there would be a status level in log4net but
|
||||
// failing that, we will print out to console instead.
|
||||
MainConsole.Instance.Output("Region {0} - LOGINS DISABLED DURING INITIALIZATION.", null, m_scene.Name);
|
||||
MainConsole.Instance.Output("Region {0} - LOGINS DISABLED DURING INITIALIZATION.", m_scene.Name);
|
||||
|
||||
if (m_uri != string.Empty)
|
||||
{
|
||||
@@ -232,7 +232,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
|
||||
// without info log messages enabled. Making this a warning is arguably misleading since it isn't a
|
||||
// warning, and monitor scripts looking for warn/error/fatal messages will received false positives.
|
||||
// Arguably, log4net needs a status log level (like Apache).
|
||||
MainConsole.Instance.Output("INITIALIZATION COMPLETE FOR {0} - LOGINS ENABLED", null, m_scene.Name);
|
||||
MainConsole.Instance.Output("INITIALIZATION COMPLETE FOR {0} - LOGINS ENABLED", m_scene.Name);
|
||||
}
|
||||
|
||||
m_scene.SceneGridService.InformNeighborsThatRegionisUp(
|
||||
|
||||
@@ -327,7 +327,7 @@ namespace OpenSim.Region.OptionalModules.World.AutoBackup
|
||||
m_busy = false;
|
||||
}
|
||||
if (!found)
|
||||
MainConsole.Instance.Output("No such region {0}. Nothing to backup", null, name);
|
||||
MainConsole.Instance.Output("No such region {0}. Nothing to backup", name);
|
||||
}
|
||||
|
||||
private void ParseDefaultConfig(IConfig config)
|
||||
|
||||
@@ -145,7 +145,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Attachments
|
||||
cdl.AddRow("teleport", m_scene.DebugTeleporting);
|
||||
cdl.AddRow("updates", m_scene.DebugUpdates);
|
||||
|
||||
MainConsole.Instance.Output("Scene {0} options:", null, m_scene.Name);
|
||||
MainConsole.Instance.Output("Scene {0} options:", m_scene.Name);
|
||||
MainConsole.Instance.Output(cdl.ToString());
|
||||
}
|
||||
|
||||
@@ -160,7 +160,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Attachments
|
||||
string value = args[4];
|
||||
SetSceneDebugOptions(new Dictionary<string, string>() { { key, value } });
|
||||
|
||||
MainConsole.Instance.Output("Set {0} debug scene {1} = {2}", null, m_scene.Name, key, value);
|
||||
MainConsole.Instance.Output("Set {0} debug scene {1} = {2}", m_scene.Name, key, value);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user