Class YComparator
java.lang.Object
com.devcharles.piazzapanic.utility.YComparator
- All Implemented Interfaces:
Comparator<com.badlogic.ashley.core.Entity>
Compares entities by their Y coordinate, so entities that are lower on the
screen appear in front for a consistent perspective.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
compare
(com.badlogic.ashley.core.Entity entityA, com.badlogic.ashley.core.Entity entityB) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
YComparator
public YComparator()
-
-
Method Details
-
compare
public int compare(com.badlogic.ashley.core.Entity entityA, com.badlogic.ashley.core.Entity entityB) - Specified by:
compare
in interfaceComparator<com.badlogic.ashley.core.Entity>
-