Optimize GC caused by playing motions.
This commit is contained in:
@@ -180,8 +180,13 @@ namespace Cryville.Crtr.Event {
|
|||||||
Children[cev].CopyTo(dest.Children[cev]);
|
Children[cev].CopyTo(dest.Children[cev]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
foreach (var m in dest.PlayingMotions) {
|
||||||
|
if (m.Value.CloneTypeFlag == dest.CloneType) dest._rmvpa.Return(m.Value);
|
||||||
|
}
|
||||||
dest.PlayingMotions.Clear();
|
dest.PlayingMotions.Clear();
|
||||||
foreach (var m in PlayingMotions) dest.PlayingMotions.Add(m.Key, m.Value);
|
foreach (var m in PlayingMotions) {
|
||||||
|
dest.PlayingMotions.Add(m.Key, m.Value);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool Disposed {
|
public bool Disposed {
|
||||||
|
|||||||
Reference in New Issue
Block a user