What is best way to purge old players?

Discussion in 'Bukkit Help' started by LHammonds, Apr 25, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    LHammonds

    As a server lingers on, what is the best way to purge inactive players? For example, if a players has not logged on in over 2 weeks, what is the best way to purge that user?

    The user might have been a leader of a faction...might have a bunch of locked chests (lockette or deadbolt)....might have had worldguard regions, etc.

    I've done some searching on Bukkit and Essential commands but have not found a purge/delete/clean utility yet.

    LHammonds
     
  2. Offline

    jaboy

    there is no real way of doing it ... some plugins an clean up the player files in the world folder ... but i have yet to see ways / tools that can remove a player from all plugins
     
  3. Offline

    LHammonds

    I wonder if it can be done using a Bash script on a Linux box.

    EDIT:

    For just the player files, one could look at the date/time stamp of the players file in world\players\*.dat

    If file date is older than allowed inactivity, the name can be used from that file and then the file deleted (or moved to a different folder if in use).

    Will need to examine each plugin to see how a player info can be removed if the name is known.

    LHammonds
     
  4. Offline

    Shevchik

    You can also do this for Essentials userdata, but other plugins mostly store their info in one file/database.


    How it can be done by a custom plugin:

    WorldGuard: use WG api
    get regions
    get owners
    check owners
    remove region

    LWC: LWC api
    get LWC database
    check every protection by getting BukkitOwner and checking him
    remove protection

    Essentials:
    opening every file and checking logout field

    .dat file
    get Offline Player
    check them
    remove files.
     
Thread Status:
Not open for further replies.

Share This Page