浏览代码

Reset from Python will clear the Agents Actions callbacks (#3249)

/asymm-envs
GitHub 5 年前
当前提交
e87901b8
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/RpcCommunicator.cs

7
UnitySDK/Assets/ML-Agents/Scripts/Grpc/RpcCommunicator.cs


}
case CommandProto.Reset:
{
foreach (var brainName in m_ActionCallbacks.Keys)
{
m_ActionCallbacks[brainName].Clear();
}
ResetCommandReceived?.Invoke();
return;
}

agentActionDict[agentId] = agentAction;
m_ActionCallbacks[brainName][i].Callback.Invoke(agentAction);
}
}
foreach (var brainName in m_ActionCallbacks.Keys)
{
m_ActionCallbacks[brainName].Clear();
}
}

正在加载...
取消
保存