Get UserMap in Essentials

Discussion in 'Plugin Development' started by ZephireNZ, Jan 21, 2013.

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

    ZephireNZ

    This is probably pretty silly, but what am I doing wrong here?

    Code:
    UserMap map = Essentials.getUserMap();
    
    Eclipse is giving out an error saying "Cannot make a static reference to the non-static method getUserMap() from the type Essentials"

    I'm trying to make a plugin that will get Bans from Essentials, specifically about temp bans and reasons for bans.
     
  2. Offline

    caseif

    When you attempt to get the method with Essentials.*, you're referencing it in a static fashion, as Essentials is a variable type. Eclipse is informing you that the method is not specified as static, meaning you can't do this. I don't have any experience with referencing other plugins so the only suggestion I can make is to manually get the user's associated YAML file from the Essentials folder. Maybe someone else will be by to help you in a bit. :D
     
  3. Offline

    ZephireNZ

    Yeah, the main problem is the YAML provides no parseable info about temp ban lengths, it seems to be a reference to a ban length (A long, non descript number).
     
Thread Status:
Not open for further replies.

Share This Page