diff --git a/app/PullRequest.cs b/app/PullRequest.cs index 5e0a1f2..104d82a 100644 --- a/app/PullRequest.cs +++ b/app/PullRequest.cs @@ -162,8 +162,9 @@ public static class PullRequest { public float p, i; float integral = 0f; float value = 0f; + // float scalar = 1f; - public PID(float p, float i) { + public PID(float p = 1, float i = 0.1f) { this.p = p; this.i = i; } diff --git a/app/Space/Mono.cs b/app/Space/Mono.cs index 6db5187..9ee14b4 100644 --- a/app/Space/Mono.cs +++ b/app/Space/Mono.cs @@ -14,6 +14,10 @@ public class Mono { List enemies = new List(); float spawnTime; + Oriels.PullRequest.PID pidX = new Oriels.PullRequest.PID(); + Oriels.PullRequest.PID pidY = new Oriels.PullRequest.PID(); + Oriels.PullRequest.PID pidZ = new Oriels.PullRequest.PID(); + Mesh meshCube; public Mono() { @@ -143,11 +147,6 @@ public class Mono { } // design variables - - // move back up and put 2 variables instead down here - // instantiate with default values - // scalar functionality for PID - Oriels.PullRequest.PID pidX = new Oriels.PullRequest.PID(8, 0.3f); - Oriels.PullRequest.PID pidY = new Oriels.PullRequest.PID(8, 0.3f); - Oriels.PullRequest.PID pidZ = new Oriels.PullRequest.PID(8, 0.3f); + float moveP = 8f; + float moveI = 0.2f; }