浏览代码

fix iteration restart

Call OnIterationEnd for randomizers that have already started when we restart the Iteration
/h-i
Mohsen Kamalzadeh 3 年前
当前提交
b6f3e784
共有 1 个文件被更改,包括 9 次插入0 次删除
  1. 9
      com.unity.perception/Runtime/Randomization/Scenarios/ScenarioBase.cs

9
com.unity.perception/Runtime/Randomization/Scenarios/ScenarioBase.cs


return;
}
var randomizersStartedThisIteration = new List<Randomizer>();
// Perform new iteration tasks
if (currentIterationFrame == 0)
{

foreach (var randomizer in activeRandomizers)
{
randomizer.IterationStart();
randomizersStartedThisIteration.Add(randomizer);
{
foreach (var rand in randomizersStartedThisIteration)
{
rand.IterationEnd();
}
randomizersStartedThisIteration.Clear();
}
if (m_ShouldDelayIteration)
{

正在加载...
取消
保存