Example #1
0
            public override bool Equals(object rhsObj)
            {
                if (rhsObj == null)
                {
                    return(false);
                }

                Good3 rhs = rhsObj as Good3;

                return(m_firstName == rhs.m_firstName && m_lastName == rhs.m_lastName);
            }
Example #2
0
            public override bool Equals(object obj)
            {
                Good3 rhs = obj as Good3;

                if ((object)rhs == null)
                {
                    return(false);
                }

                return(name == rhs.name && weight == rhs.weight);
            }
Example #3
0
            public override bool Equals(object rhsObj)
            {
                if (rhsObj == null)
                {
                    return(false);
                }

                Good3 rhs = (Good3)rhsObj;

                return(this == rhs);
            }
Example #4
0
            public override bool Equals(object rhsObj)
            {
                if (rhsObj == null)
                {
                    return(false);
                }

                if (GetType() != rhsObj.GetType())
                {
                    return(false);
                }

                Good3 rhs = (Good3)rhsObj;

                return(x == rhs.x && y == rhs.y);
            }
Example #5
0
            // Equals matches GetHashCode
            public override bool Equals(object rhsObj)
            {
                if (object.ReferenceEquals(this, rhsObj))
                {
                    return(true);
                }

                Good3 rhs = rhsObj as Good3;

                if (rhs == null)
                {
                    return(false);
                }

                return(name == rhs.name && address == rhs.address);
            }
 public void Verify3E()
 {
     if (!Timer.gameEnded && !EquationControl.verified3 && !EquationControl.controlLoss)
     {
         if (EquationControl.n6 == EquationControl.CorrectInts[2])
         {
             Bad3.SetActive(false);
             Good3.SetActive(true);
             FindObjectOfType <SoundManager>().PlaySound("success3");
             EquationControl.score++;
             EquationControl.verified3 = true;
         }
         else
         {
             FindObjectOfType <SoundManager>().PlaySound("incorrectanswer");
             Bad3.SetActive(true);
         }
     }
 }
Example #7
0
 public static Point ToPointType(Good3 size)
 {
     return new Point(size.m_width, size.m_height);
 }
Example #8
0
 public static Point ToPointType(Good3 size)
 {
     return(new Point(size.m_width, size.m_height));
 }
Example #9
0
 // OK to access non-this field.
 public void Write(Good3 other)
 {
     Console.WriteLine(other.flag);
 }
Example #10
0
 // OK to call a non-this method.
 public void Write(Good3 other, string message)
 {
     other.Write(message);
 }
Example #11
0
 public bool Equals(Good3 rhs)
 {
     return this == rhs;
 }
Example #12
0
 public bool Equals(Good3 rhs)
 {
     return(this == rhs);
 }