Hello Sponge! This is the PvPLogger plugin! Here is a little bit about what it does. Ever have the problem of players leaving during combat? This plugin provides a solution to this. When struck by another player, you are “engaged in combat” for 10 seconds, and if you leave, the set punishment is applied. All comments, suggestions, and feedback are extremely appreciated!
Downloads
You can head over to the GitHub page to grab the latest build of PvPLogger here.
GitHub Repository
If you’d like to check out PvPLogger’s GitHub repo, you can do so here.
Image Examples :
Engaged In Combat :
Player Leaves During Combat :
When Player Joins Back:
Punishment Is Applied!
Commands
/setpunishment <punishment> - Sets the punishment for players after PvP Logging.
Is it possible that when a player tries to escape by closing client, the plugin kills him before he logs out? So, I mean, even the player has closed the client, his body will still stay on the server for a while and then be killed by the plugin.
Technically I think not, but it should be possible to spawn an NPC and transfer the player’s inventory to it which would essentially provide the same effect.
There is 2 ways to accomplish that from a programming point of view, one is to never remove the player entity, and trick the server into thinking they are still connected.
The other is to replace them with an NPC as @AsyDRabbit said.