how to call the list of players in the town and check the kick, exit from the town? #4999
Answered
by
LlmDl
Ru5D1mG4me
asked this question in
Q&A
-
Hello, I am writing a plugin for passports, but I am facing a problem. I re-read all the API documentation, but I couldn't find anything for my problem. How to find out in the code which players are in the town(list)? And one more question how to track that the player left the town or was kicked? |
Beta Was this translation helpful? Give feedback.
Answered by
LlmDl
Jun 10, 2021
Replies: 1 comment 1 reply
-
You can use town.getResidents() to get the players who belong to a town. The TownLeaveEvent and TownKickEvent are events Towny throws to let you know when players are losing their Town. |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
LlmDl
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can use town.getResidents() to get the players who belong to a town.
The TownLeaveEvent and TownKickEvent are events Towny throws to let you know when players are losing their Town.