Skip to content

Commit

Permalink
fix crash in axis constraints application when not connecting any n64…
Browse files Browse the repository at this point in the history
… controllers (fixes #946)
  • Loading branch information
zeromus committed Jul 29, 2017
1 parent 66955ca commit 89e87bc
Showing 1 changed file with 2 additions and 0 deletions.
Expand Up @@ -85,6 +85,8 @@ public void ApplyAxisConstraints(string constraintClass, IDictionary<string, flo
string xaxis = constraint.Params[0] as string;
string yaxis = constraint.Params[1] as string;
float range = (float)constraint.Params[2];
if (!floatButtons.ContainsKey(xaxis)) break;
if (!floatButtons.ContainsKey(yaxis)) break;
double xval = floatButtons[xaxis];
double yval = floatButtons[yaxis];
double length = Math.Sqrt((xval * xval) + (yval * yval));
Expand Down

0 comments on commit 89e87bc

Please sign in to comment.