TryGetValue() for a nice time
This commit is contained in:
@@ -48,9 +48,9 @@ namespace OpenMetaverse.TestClient
|
||||
else if (arg.ToLower().Equals("show"))
|
||||
{
|
||||
Client.Self.SignaledAnimations.ForEach(delegate(KeyValuePair<UUID, int> kvp) {
|
||||
if (m_BuiltInAnimations.ContainsKey(kvp.Key))
|
||||
if (m_BuiltInAnimations.TryGetValue(kvp.Key, out var animation))
|
||||
{
|
||||
result.AppendFormat("The {0} System Animation is being played, sequence is {1}", m_BuiltInAnimations[kvp.Key], kvp.Value);
|
||||
result.AppendFormat("The {0} System Animation is being played, sequence is {1}", animation, kvp.Value);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -72,8 +72,8 @@ namespace OpenMetaverse.TestClient
|
||||
{
|
||||
if (prim.ParentID == 0)
|
||||
{
|
||||
if (linksets.ContainsKey(prim.LocalID))
|
||||
linksets[prim.LocalID].RootPrim = prim;
|
||||
if (linksets.TryGetValue(prim.LocalID, out var linkset))
|
||||
linkset.RootPrim = prim;
|
||||
else
|
||||
linksets[prim.LocalID] = new Linkset(prim);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user