Where does Essentials store mail that hasn't been read?

Discussion in 'Bukkit Help' started by MaliciousMan, Aug 3, 2013.

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

    MaliciousMan

    I was looking for the destination. Sorry if I didn't provide enough info, I feel like I haven't xD

    I need to delete a message that was sent to all players. Thanks guys.
     
  2. Offline

    naithantu

    Essentials plugin folder -> userdata

    The mail will be in the yml file of the player it was sent to
     
  3. Offline

    MaliciousMan

    Crap, it was sent to over a thousand people. Is there any way to clear ALL mail without going one by one deleting them all?

    **Edit Sorry I left this thread open for so long, I was busy with other things on the server, mail was near the bottom. :D
     
  4. Offline

    MegaCow2011

    theres probably no way. Why not just tell the players to delete them selves :p,
     
  5. Offline

    MaliciousMan

    That's what I would have to do, its just that I'm starting a brand new server, but taking user data from the old one since it contains the players' saved money.

    Is money stored anywhere else? Or can it be set to save to it's own file? I use Vault.
     
  6. Offline

    MegaCow2011

    i think you would want to bring BOTH jars (And the other essentials plugins JARS) , and files with you to the new server. That is the safest way.
    MegaCow2011
     
  7. Offline

    MaliciousMan

    Same plugins, different world and different configs. I just want players coming back to not have unread mail. HelpfulBeast please help!
     
  8. Offline

    MegaCow2011

    well, why not just transport the plugin entirely?
    why do you want to reatart it?
     
  9. Offline

    MaliciousMan

    I am, I just want to delete all mail from the userdata.
    I don't want to restart it, I just don't want pending mail for my players. And I can't go through each one since that would take like a week.
     
  10. Offline

    LandonTheGeek

    MaliciousMan

    Thanks for Tahg. :) Although, I am not very sure I know the answer to this. I would guess to reload the .jars, and transfer the saved data to the folder and see if that helps.

    Sorry,
    Beast
     
  11. Offline

    MaliciousMan

    I don't think I explained correctly... Ok...

    I have essentials and vault, when you get money it makes a variable "money" equal to however much you have but it puts it in a file with this format:
    Code:
    money: 10.0
    timestamps:
      login: 1370151188031
      lastteleport: 1370153972593
      logout: 1370154404156
    ipAddress: xxx.193.231.86
    lastlocation:
      world: Survival
      x: -884.3135059243318
      y: 76.0
      z: 19.111494733409042
      yaw: 159.08691
      pitch: 15.043234
    logoutlocation:
      world: Survival
      x: -501.90148947186754
      y: 64.0
      z: 384.68585647953876
      yaw: 159.12892
      pitch: 19.343996
    homes:
      home:
        world: Survival
        x: -832.9489093060016
        y: 78.0
        z: -32.53904593707814
        yaw: 71.267365
        pitch: 13.082429
    mail:
    - 'minecraft_123_go: Hey Guys, Welcome to Teh Server!'
    - 'Adriano: Sorry for the server being off guys -Adriano'
    - 'minecraft_123_go: Curosity killed the cat. :D'
    - 'minecraft_123_go: Should we get factions? email me'
    - 'minecraft_123_go: Please let us know'
    - 'Server: '
    - 'Server: will be whitelisted MONDAY for addition of new plugins and updating of
      old ones. People to be added to the Whitelist: Adriano[OzOwnz] and minecraft_123_go.
      Have a nice day xD.'
    
    Every user has their own userdata file. Screenshot supplied:
    [​IMG]
    Sorry, keeping my player's names hidden :D. Anyways, I want to delete the mail section in EACH of them. When I said a thousand, I meant like more, this is just a few. I edited the screenshot to show only a few.
     
  12. Offline

    Necrodoom

    could probably use some batch script to remove the mail data from file. essentials only offers file reset/eco/powertool as mass player commands right now, though having an unread mail is not really considered a problem. you can still suggest it in the issue/feature tracker of essentials, though.
     
  13. Offline

    MaliciousMan



    The only problem with using a batch script is that the mail is usually at the bottom. Essentials randomly places it's variables in any order, and some of the userdata have the mail read and deleted.

    I'll go suggest it in the feature page of essentials.
     
  14. Offline

    Bobcat00

    A script would be pretty easy to write. Read and write each line in the .yml file until you find "mail:" starting in column 1, then skip until you find something other than a space or "-" in column 1 (and handle end-of-file).

    Note that the mail section is not necessarily at the bottom of the file.
     
  15. Offline

    MaliciousMan

    Sounds easy, I have absolutely no experience with batch files... I'm searching for info right now. I'll get back to you when I find a way.
     
  16. I'm also having this problem, has any solution been found?

    I'd rather not have to go through 22,500 userdata files one by one and have yet to discover a find and replace tool that effectively deals with clearing all text after a string or working with variable strings (due to different mail messages).
     
  17. Offline

    Necrodoom

    luigiofthebakery as explained, google for scripts or look into text editor functions. This isn't really a hard to find one.
     
Thread Status:
Not open for further replies.

Share This Page