-
Notifications
You must be signed in to change notification settings - Fork 4.4k
csharp cleanup #3392
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
csharp cleanup #3392
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,7 @@ | ||
| using Barracuda; | ||
| using System; | ||
| using System.Collections.Generic; | ||
| using UnityEngine; | ||
| using UnityEngine.Serialization; | ||
|
|
||
| namespace MLAgents | ||
| { | ||
|
|
@@ -13,7 +13,7 @@ namespace MLAgents | |
| public class BehaviorParameters : MonoBehaviour | ||
| { | ||
| [Serializable] | ||
| private enum BehaviorType | ||
| enum BehaviorType | ||
| { | ||
| Default, | ||
| HeuristicOnly, | ||
|
|
@@ -37,11 +37,12 @@ private enum BehaviorType | |
| string m_BehaviorName = "My Behavior"; | ||
| [HideInInspector] | ||
| [SerializeField] | ||
| public int m_TeamID = 0; | ||
| public int m_TeamID; | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is still public with |
||
| [FormerlySerializedAs("m_useChildSensors")] | ||
| [HideInInspector] | ||
| [SerializeField] | ||
| [Tooltip("Use all Sensor components attached to child GameObjects of this Agent.")] | ||
| bool m_useChildSensors = true; | ||
| bool m_UseChildSensors = true; | ||
|
|
||
| public BrainParameters brainParameters | ||
| { | ||
|
|
@@ -50,7 +51,7 @@ public BrainParameters brainParameters | |
|
|
||
| public bool useChildSensors | ||
| { | ||
| get { return m_useChildSensors; } | ||
| get { return m_UseChildSensors; } | ||
| } | ||
|
|
||
| public string behaviorName | ||
|
|
@@ -93,13 +94,13 @@ internal IPolicy GeneratePolicy(Func<float[]> heuristic) | |
| } | ||
|
|
||
| public void GiveModel( | ||
| string behaviorName, | ||
| string newBehaviorName, | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Argument name shadowed the |
||
| NNModel model, | ||
| InferenceDevice inferenceDevice = InferenceDevice.CPU) | ||
| { | ||
| m_Model = model; | ||
| m_InferenceDevice = inferenceDevice; | ||
| m_BehaviorName = behaviorName; | ||
| m_BehaviorName = newBehaviorName; | ||
| } | ||
| } | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andrewcoh A few unused variables from soccer. Just want to make sure there's no plans to bring these back.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah I missed this. Good to remove.