Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## edu.cwru.SimpleRTS.util
Class DistanceMetrics

    java.lang.Object
      edu.cwru.SimpleRTS.util.DistanceMetrics

    public final class DistanceMetrics

extends java.lang.Object

Method Summary
`static int` | `chebyshevDistance(int x1, int y1, int x2, int y2)` The core distance metric used by wargus for attacks and such
`static double` | `euclideanDistance(int x1, int y1, int x2, int y2)`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### euclideanDistance

    public static double euclideanDistance(int x1,
                                           int y1,
                                           int x2,
                                           int y2)

### chebyshevDistance

    public static int chebyshevDistance(int x1,
                                        int y1,
                                        int x2,
                                        int y2)

  The core distance metric used by wargus for attacks and such

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD