minor meaningless changes

afrisby
Jeff Ames 2007-12-03 07:26:27 +00:00
parent c8faccb396
commit 4c0ddacc16
4 changed files with 34 additions and 51 deletions

View File

@ -177,7 +177,7 @@ namespace OpenSim.Framework.Communications
}
/// <summary>
/// Build a Uri based on the intial Url, path elements and parameters
/// Build a Uri based on the initial Url, path elements and parameters
/// </summary>
/// <returns>fully constructed Uri</returns>
private Uri buildUri()
@ -250,7 +250,7 @@ namespace OpenSim.Framework.Communications
}
/// <summary>
/// Async method, invoked when the intial response if received from the server
/// Async method, invoked when the initial response if received from the server
/// </summary>
/// <param name="ar"></param>
private void ResponseIsReadyDelegate(IAsyncResult ar)

View File

@ -5,6 +5,6 @@ namespace OpenSim.Region.Environment.Interfaces
{
public interface IAvatarFactory : IRegionModule
{
bool TryGetIntialAvatarAppearance(LLUUID avatarId, out AvatarWearable[] wearables, out byte[] visualParams);
bool TryGetInitialAvatarAppearance(LLUUID avatarId, out AvatarWearable[] wearables, out byte[] visualParams);
}
}

View File

@ -14,20 +14,20 @@ namespace OpenSim.Region.Environment.Modules
private Scene m_scene = null;
private Dictionary<LLUUID, AvatarAppearance> m_avatarsClothes = new Dictionary<LLUUID, AvatarAppearance>();
public bool TryGetIntialAvatarAppearance(LLUUID avatarId, out AvatarWearable[] wearables,
out byte[] visualParams)
public bool TryGetInitialAvatarAppearance(LLUUID avatarId, out AvatarWearable[] wearables,
out byte[] visualParams)
{
if (!m_avatarsClothes.ContainsKey(avatarId))
if (m_avatarsClothes.ContainsKey(avatarId))
{
GetDefaultAvatarAppearance(out wearables, out visualParams);
AvatarAppearance wearing = new AvatarAppearance(wearables);
m_avatarsClothes[avatarId] = wearing;
visualParams = GetDefaultVisualParams();
wearables = m_avatarsClothes[avatarId].IsWearing;
return true;
}
else
{
visualParams = GetDefaultVisualParams();
wearables = m_avatarsClothes[avatarId].IsWearing;
GetDefaultAvatarAppearance(out wearables, out visualParams);
AvatarAppearance wearing = new AvatarAppearance(wearables);
m_avatarsClothes[avatarId] = wearing;
return true;
}
}
@ -76,29 +76,29 @@ namespace OpenSim.Region.Environment.Modules
IClientAPI clientView = (IClientAPI)sender;
//Todo look up the assetid from the inventory cache (or something) for each itemId that is in AvatarWearingArgs
// then store assetid and itemId and wearable type in a database
foreach (AvatarWearingArgs.Wearable wear in e.NowWearing)
foreach (AvatarWearingArgs.Wearable wear in e.NowWearing)
{
if (wear.Type < 13)
{
if (wear.Type < 13)
LLUUID assetId;
CachedUserInfo profile = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(clientView.AgentId);
if (profile != null)
{
LLUUID assetId;
CachedUserInfo profile = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(clientView.AgentId);
if (profile != null)
InventoryItemBase baseItem = profile.RootFolder.HasItem(wear.ItemID);
if (baseItem != null)
{
InventoryItemBase baseItem = profile.RootFolder.HasItem(wear.ItemID);
if (baseItem != null)
assetId = baseItem.assetID;
//temporary dictionary storage. This should be storing to a database
if (m_avatarsClothes.ContainsKey(clientView.AgentId))
{
assetId = baseItem.assetID;
//temporary dictionary storage. This should be storing to a database
if (m_avatarsClothes.ContainsKey(clientView.AgentId))
{
AvatarAppearance avWearing = m_avatarsClothes[clientView.AgentId];
avWearing.IsWearing[wear.Type].AssetID = assetId;
avWearing.IsWearing[wear.Type].ItemID = wear.ItemID;
}
AvatarAppearance avWearing = m_avatarsClothes[clientView.AgentId];
avWearing.IsWearing[wear.Type].AssetID = assetId;
avWearing.IsWearing[wear.Type].ItemID = wear.ItemID;
}
}
}
}
}
}
public static void GetDefaultAvatarAppearance(out AvatarWearable[] wearables, out byte[] visualParams)
@ -155,5 +155,4 @@ namespace OpenSim.Region.Environment.Modules
}
}
}
}

View File

@ -251,7 +251,6 @@ namespace OpenSim.Region.Environment.Scenes
httpListener = httpServer;
m_dumpAssetsToFile = dumpAssetsToFile;
}
#endregion
@ -311,8 +310,6 @@ namespace OpenSim.Region.Environment.Scenes
m_restartTimer.Start();
SendGeneralAlert(RegionInfo.RegionName + ": Restarting in 2 Minutes");
}
}
public void RestartTimer_Elapsed(object sender, ElapsedEventArgs e)
@ -329,7 +326,6 @@ namespace OpenSim.Region.Environment.Scenes
m_restartTimer.AutoReset = false;
RestartNow();
}
}
public void RestartNow()
@ -392,7 +388,6 @@ namespace OpenSim.Region.Environment.Scenes
});
m_heartbeatTimer.Close();
m_innerScene.Close();
UnRegisterReginWithComms();
@ -407,7 +402,6 @@ namespace OpenSim.Region.Environment.Scenes
Modules.Clear();
base.Close();
}
/// <summary>
@ -568,7 +562,6 @@ namespace OpenSim.Region.Environment.Scenes
}
});
Terrain.ResetTaint();
}
}
@ -631,7 +624,7 @@ namespace OpenSim.Region.Environment.Scenes
}
}
foreach(AssetBase asset in textures)
foreach (AssetBase asset in textures)
{
System.Drawing.Image image= OpenJPEGNet.OpenJPEG.DecodeToImage(asset.Data);
bitImages.Add(image);
@ -642,7 +635,7 @@ namespace OpenSim.Region.Environment.Scenes
System.Drawing.SolidBrush sea = new System.Drawing.SolidBrush(System.Drawing.Color.DarkBlue);
g.FillRectangle(sea, 0, 0, 2560, 2560);
for(int i =0; i<mapBlocks.Count; i++)
for (int i = 0; i < mapBlocks.Count; i++)
{
ushort x = (ushort) ((mapBlocks[i].X - this.RegionInfo.RegionLocX) + 10);
ushort y = (ushort) ((mapBlocks[i].Y - this.RegionInfo.RegionLocY) + 10);
@ -692,7 +685,6 @@ namespace OpenSim.Region.Environment.Scenes
CreateTerrainTexture(false);
//CommsManager.GridService.RegisterRegion(RegionInfo); //hack to update the terrain texture in grid mode so it shows on world map
}
catch (Exception e)
{
@ -726,7 +718,6 @@ namespace OpenSim.Region.Environment.Scenes
AssetCache.AddAsset(asset);
}
#endregion
#region Primitives Methods
@ -795,7 +786,6 @@ namespace OpenSim.Region.Environment.Scenes
/// <param name="ownerID"></param>
public virtual void AddNewPrim(LLUUID ownerID, LLVector3 pos, LLQuaternion rot, PrimitiveBaseShape shape)
{
// What we're *supposed* to do is raytrace from the camera position given by the client to the nearest collision
// in the direction the client supplies (the ground level that we clicked)
// This function is pretty crappy right now.. so we're not affecting where the newly rezzed objects go
@ -813,7 +803,6 @@ namespace OpenSim.Region.Environment.Scenes
Ray rezRay = new Ray(CameraPosition, rayDirection);
Vector3 RezDirectionFromCamera = rezRay.Direction;
EntityIntersection rayTracing = m_innerScene.GetClosestIntersectingPrim(rezRay);
@ -838,7 +827,6 @@ namespace OpenSim.Region.Environment.Scenes
MainLog.Instance.Verbose("REZINFO", "Possible Rez Point:" + RezPoint.ToString());
//pos = new LLVector3(RezPoint.x, RezPoint.y, RezPoint.z);
}
else
{
@ -846,7 +834,6 @@ namespace OpenSim.Region.Environment.Scenes
pos.Z += 0.25F;
}
SceneObjectGroup sceneOb =
new SceneObjectGroup(this, m_regionHandle, ownerID, PrimIDAllocate(), pos, rot, shape);
AddEntity(sceneOb);
@ -871,7 +858,6 @@ namespace OpenSim.Region.Environment.Scenes
new Quaternion(), UsePhysics);
// subscribe to physics events.
rootPart.DoPhysicsPropertyUpdate(UsePhysics, true);
}
}
}
@ -1037,13 +1023,12 @@ namespace OpenSim.Region.Environment.Scenes
protected void LoadAvatarAppearance(IClientAPI client, out byte[] visualParams, out AvatarWearable[] wearables)
{
if (m_AvatarFactory == null ||
!m_AvatarFactory.TryGetIntialAvatarAppearance(client.AgentId, out wearables, out visualParams))
!m_AvatarFactory.TryGetInitialAvatarAppearance(client.AgentId, out wearables, out visualParams))
{
AvatarFactoryModule.GetDefaultAvatarAppearance(out wearables, out visualParams);
}
}
/// <summary>
///
/// </summary>
@ -1066,7 +1051,6 @@ namespace OpenSim.Region.Environment.Scenes
}
});
ForEachScenePresence(
delegate(ScenePresence presence) { presence.CoarseLocationChange(); });
@ -1096,8 +1080,6 @@ namespace OpenSim.Region.Environment.Scenes
// Remove client agent from profile, so new logins will work
CommsManager.UserService.clearUserAgent(agentID);
return;
}
public void NotifyMyCoarseLocationChange()
@ -1223,6 +1205,7 @@ namespace OpenSim.Region.Environment.Scenes
{
m_sceneGridService.EnableNeighbourChildAgents(presence);
}
public void InformClientOfNeighbor(ScenePresence presence, RegionInfo region)
{
m_sceneGridService.InformNeighborChildAgent(presence, region);
@ -1281,6 +1264,7 @@ namespace OpenSim.Region.Environment.Scenes
#endregion
#region Module Methods
public void AddModule(string name, IRegionModule module)
{
if (!Modules.ContainsKey(name))
@ -1308,9 +1292,11 @@ namespace OpenSim.Region.Environment.Scenes
return default(T);
}
}
#endregion
#region Other Methods
public void SetTimePhase(int phase)
{
m_timePhase = phase;
@ -1343,7 +1329,6 @@ namespace OpenSim.Region.Environment.Scenes
m_LandManager.landPrimCountTainted = false;
}
public void addPrimsToParcelCounts()
{
foreach (EntityBase obj in Entities.Values)
@ -1409,7 +1394,6 @@ namespace OpenSim.Region.Environment.Scenes
{
m_scenePresences[agentID].ControllingClient.SendAgentAlertMessage("Request for god powers denied", false);
}
}
public void handleGodlikeKickUser(LLUUID godid, LLUUID sessionid, LLUUID agentid, uint kickflags, byte[] reason)