Jump to content

return true if any other player is on a certain tile


Recommended Posts

Posted (edited)

Position pos = new Position(x, y, z);

boolean playerOnPosition = !getPlayers().filter(new PositionFilter<>(pos)).isEmpty();

 

Just wrote it out in here, so the syntax might be slightly off. But the concept should work.

 

EDIT: nevermind; what Flamez said is a better approach

Edited by FrostBug

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...