replace my hack by others hack

This commit is contained in:
UbitUmarov
2019-01-01 12:06:29 +00:00
parent 813fda90da
commit 02492f7b15
10 changed files with 71 additions and 62 deletions

View File

@@ -3111,12 +3111,6 @@ namespace OpenSim.Region.Framework.Scenes
m_LastLogin = Util.EnvironmentTickCount();
//HACK only send object animations to fs beta for now
string viewername = Util.GetViewerName(aCircuit);
if(sp != null && viewername.StartsWith("Firestorm-Betax64 6"))
{
sp.ControllingClient.DoObjectAnimations = true;
}
return sp;
}
@@ -3207,36 +3201,29 @@ namespace OpenSim.Region.Framework.Scenes
public override bool CheckClient(UUID agentID, System.Net.IPEndPoint ep)
{
AgentCircuitData aCircuit = m_authenticateHandler.GetAgentCircuitData(agentID);
if (aCircuit != null)
if (aCircuit == null)
return false;
bool vialogin = false;
if (VerifyClient(aCircuit, ep, out vialogin))
return true;
// if it doesn't pass, we remove the agentcircuitdata altogether
// and the scene presence and the client, if they exist
try
{
bool vialogin = false;
if (!VerifyClient(aCircuit, ep, out vialogin))
ScenePresence sp = WaitGetScenePresence(agentID);
if (sp != null)
{
// if it doesn't pass, we remove the agentcircuitdata altogether
// and the scene presence and the client, if they exist
try
{
ScenePresence sp = WaitGetScenePresence(agentID);
if (sp != null)
{
PresenceService.LogoutAgent(sp.ControllingClient.SessionId);
CloseAgent(sp.UUID, false);
}
// BANG! SLASH!
m_authenticateHandler.RemoveCircuit(agentID);
return false;
}
catch (Exception e)
{
m_log.DebugFormat("[SCENE]: Exception while closing aborted client: {0}", e.StackTrace);
}
PresenceService.LogoutAgent(sp.ControllingClient.SessionId);
CloseAgent(sp.UUID, false);
}
else
return true;
// BANG! SLASH!
m_authenticateHandler.RemoveCircuit(agentID);
}
catch (Exception e)
{
m_log.DebugFormat("[SCENE]: Exception while closing aborted client: {0}", e.StackTrace);
}
return false;

View File

@@ -45,6 +45,7 @@ using OpenSim.Region.PhysicsModules.SharedBase;
using GridRegion = OpenSim.Services.Interfaces.GridRegion;
using OpenSim.Services.Interfaces;
using TeleportFlags = OpenSim.Framework.Constants.TeleportFlags;
using Caps = OpenSim.Framework.Capabilities.Caps;
namespace OpenSim.Region.Framework.Scenes
{
@@ -1110,6 +1111,14 @@ namespace OpenSim.Region.Framework.Scenes
HealRate = 0.5f;
ControllingClient.SupportObjectAnimations = false;
if (m_scene.CapsModule != null)
{
Caps cap = m_scene.CapsModule.GetCapsForUser(ControllingClient.CircuitCode);
if (cap != null && (cap.Flags & Caps.CapsFlags.ObjectAnim) != 0)
ControllingClient.SupportObjectAnimations = true;
}
IConfig sconfig = m_scene.Config.Configs["EntityTransfer"];
if (sconfig != null)
{