temporary HACK to not kill some viewers

0.9.1.0-post-fixes
UbitUmarov 2018-12-31 16:58:44 +00:00
parent ae00623b65
commit 813fda90da
6 changed files with 19 additions and 4 deletions

View File

@ -710,6 +710,7 @@ namespace OpenSim.Framework
Vector3 StartPos { get; set; } Vector3 StartPos { get; set; }
UUID AgentId { get; } UUID AgentId { get; }
bool DoObjectAnimations { get; set; }
/// <summary> /// <summary>
/// The scene agent for this client. This will only be set if the client has an agent in a scene (i.e. if it /// The scene agent for this client. This will only be set if the client has an agent in a scene (i.e. if it

View File

@ -344,13 +344,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP
private Prioritizer m_prioritizer; private Prioritizer m_prioritizer;
private bool m_disableFacelights; private bool m_disableFacelights;
// needs optimazation // needs optimization
private HashSet<SceneObjectGroup> GroupsInView = new HashSet<SceneObjectGroup>(); private HashSet<SceneObjectGroup> GroupsInView = new HashSet<SceneObjectGroup>();
#pragma warning disable 0414 #pragma warning disable 0414
private bool m_VelocityInterpolate; private bool m_VelocityInterpolate;
#pragma warning restore 0414 #pragma warning restore 0414
private const uint MaxTransferBytesPerPacket = 600; private const uint MaxTransferBytesPerPacket = 600;
public bool DoObjectAnimations { get; set; }
/// <value> /// <value>
/// Maintain a record of all the objects killed. This allows us to stop an update being sent from the /// Maintain a record of all the objects killed. This allows us to stop an update being sent from the
/// thread servicing the m_primFullUpdates queue after a kill. If this happens the object persists as an /// thread servicing the m_primFullUpdates queue after a kill. If this happens the object persists as an
@ -3915,6 +3917,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
public void SendObjectAnimations(UUID[] animations, int[] seqs, UUID senderId) public void SendObjectAnimations(UUID[] animations, int[] seqs, UUID senderId)
{ {
// m_log.DebugFormat("[LLCLIENTVIEW]: Sending Object animations for {0} to {1}", sourceAgentId, Name); // m_log.DebugFormat("[LLCLIENTVIEW]: Sending Object animations for {0} to {1}", sourceAgentId, Name);
if(!DoObjectAnimations)
return;
ObjectAnimationPacket ani = (ObjectAnimationPacket)PacketPool.Instance.GetPacket(PacketType.ObjectAnimation); ObjectAnimationPacket ani = (ObjectAnimationPacket)PacketPool.Instance.GetPacket(PacketType.ObjectAnimation);
// TODO: don't create new blocks if recycling an old packet // TODO: don't create new blocks if recycling an old packet
@ -4326,10 +4330,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
if (update.Entity is SceneObjectPart) if (update.Entity is SceneObjectPart)
{ {
if (updateFlags.HasFlag(PrimUpdateFlags.Animations)) if (DoObjectAnimations && updateFlags.HasFlag(PrimUpdateFlags.Animations))
{ {
SceneObjectPart sop = (SceneObjectPart)update.Entity; SceneObjectPart sop = (SceneObjectPart)update.Entity;
if (sop.Animations != null) if ( sop.Animations != null)
{ {
ObjectAnimationUpdates.Value.Add(sop); ObjectAnimationUpdates.Value.Add(sop);
maxUpdatesBytes -= 32 * sop.Animations.Count + 16; maxUpdatesBytes -= 32 * sop.Animations.Count + 16;

View File

@ -3111,6 +3111,12 @@ namespace OpenSim.Region.Framework.Scenes
m_LastLogin = Util.EnvironmentTickCount(); 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; return sp;
} }
@ -4190,7 +4196,6 @@ namespace OpenSim.Region.Framework.Scenes
return false; return false;
} }
} }
return true; return true;
} }

View File

@ -60,6 +60,8 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server
public int PingTimeMS { get { return 0; } } public int PingTimeMS { get { return 0; } }
public bool DoObjectAnimations { get; set; }
private string m_username; private string m_username;
private string m_nick; private string m_nick;

View File

@ -73,6 +73,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
private UUID m_profileImage = UUID.Zero; private UUID m_profileImage = UUID.Zero;
private string m_born; private string m_born;
public List<uint> SelectedObjects {get; private set;} public List<uint> SelectedObjects {get; private set;}
public bool DoObjectAnimations { get; set; }
public NPCAvatar( public NPCAvatar(
string firstname, string lastname, Vector3 position, UUID ownerID, bool senseAsAgent, Scene scene) string firstname, string lastname, Vector3 position, UUID ownerID, bool senseAsAgent, Scene scene)

View File

@ -354,6 +354,8 @@ namespace OpenSim.Tests.Common
public ISceneAgent SceneAgent { get; set; } public ISceneAgent SceneAgent { get; set; }
public bool DoObjectAnimations { get; set; }
/// <value> /// <value>
/// The last caps seed url that this client was given. /// The last caps seed url that this client was given.
/// </value> /// </value>