public ProblemConfiguration() { ExtraFiles = new List <string>(); Points = new List <DataPoint>(); ComparingOptions = new ComparingOption(); Answer = new AnswerPoint(); UseStdIO = true; }
private void GradePointIntersection() { AnswerPoint.gameObject.SetActive(false); if (dropDownMenu.value != (int)DropdownChoices.POINT) { failure("טעית בבחירה, הבחירה הנכונה היא: נקודת חיתוך"); return; } if (!CheckInputVector(inputX, inputY)) { return; } Vector2 answer = GetVector2Input(inputX, inputY); AnswerPoint.gameObject.SetActive(true); AnswerPoint.gameObject.transform.position = answer; Vector2 correct = MathUtil.RoundVector(info.Point); LogInfo(answer + "\n" + correct); MeshRenderer mr = AnswerPoint.GetComponent <MeshRenderer>(); if (answer != correct) { mr.material.color = Color.red; failure("התוצאה לא נכונה"); return; } else { mr.material.color = Color.green; success(); } }