I have three Actors a, b and c. I want to that:
a is above b
b is above c
c is above a, when it isn't behind b
Is that possible?
if (getOneIntersectingObject(B.class) != null && !aboveB)
{
int x = getX(), y = getY(), w = getWorld();
w.removeObject(this);
w.addObject(this, x, y);
aboveB = true;
}
if (getOneIntersectingObject(B.class) == null && aboveB) aboveB = false;