[INACTIVE][INFO] HelpCenter v1.78 - A Flat and HTTP Helpfile/Topic Server [860]

Discussion in 'Inactive/Unsupported Plugins' started by weasel5i2, Feb 10, 2011.

  1. Offline

    weasel5i2

    HelpCenter - A Flat and HTTP Helpfile/Topic Server:
    Version: 1.78

    Description: **COLOUR CODES have CHANGED! See below...**

    This plugin allows you to serve any number of textfiles (and/or web-based texts) as help topics, using the /help command. The help files are placed in the HelpCenter/ folder, and their existence determines their availability within the game. Since the plugin reads the files each time it is invoked, any changes to the textfiles will be reflected immediately in-game. Note that the filenames must contain only characters which are enterable into the Minecraft client. It can also fetch helpfiles from a web server (the files must be in text/plain format, it will not strip out HTML tags or any weird characters, or do any unescaping() so make sure your help page(s) are returning plain text.)​

    If you create a file called HelpCenter/welcome.txt, it will be displayed to every user upon login. This is handy for displaying a message like "Type /help topics for a list of help topics." and so on..​

    If the file contains a specially crafted URL line (see below) then it will fetch the contents of a web page via the URL and return that to the player instead.​

    If the folder ./HelpCenter doesn't exist, it will be created when you first run the plugin.​

    Features:
    • Compatible with Craftbukkit running Minecraft 1.3x
    • Word-wrapping for those long lines of text
    • Dynamic: any changes to the helpfiles are reflected immediately to the players.
    • Directory traversal protection (trying "/help ../../../../../../../etc/passwd" will not work)
    • This plugin will support as many helpfiles as you can possibly create.
    • It can fetch web-based helpfiles via HTTP. :)
    • C o l o u r s ! (see codes below)
    • Default helpfile with randomly-chosen help item capability (otherwise will pass-thru the /help command if typed in without any arguments)
    • Helpfile redirection!
    Example help files:


    HelpCenter/spears.txt:
    Code:
    Spears are long and pointy. They can be used to stab things.
    You can also throw them or use them to roast hot dogs.
    ..will result in this when the player types /help spears:
    [​IMG]

    Here is an example of the text-wrapping feature. This is the help file I made:
    Code:
    The quick brown fox jumped over the lazy dogs. The quick brown fox jumped over the lazy dogs. The quick brown fox jumped over the lazy dogs. The quick brown fox jumped over the lazy dogs. The quick brown fox jumped over the lazy dogs.
    ..and here is the line-wrapping (it ended up being split into four separate lines):
    [​IMG]

    for web-based helpfiles, the format is a single line in the text file consisting of
    Code:
    [URL http://some.site.url.here..]
    e.g.: [URL http://bananas.are.nice] or [URL http://so.are.raspberries].

    If you want to make it so players can use the above example by typing "/help spear" as well, simply create a file called spear.txt and insert this redirection line:
    Code:
    [HELP spears]
    This way, you only need to update the original spears.txt to make changes to all linked helpfiles.

    Keywords (replaced by values) - If a help file contains any of the blue keywords listed below, they will be replaced by the following values, respectively:

    • %user% - Bukkit - player - The players name
    • %world% - Bukkit - player - The world the player is in
    • %health% - Bukkit - player - The players health value (0 = dead, 20 = full health)
    • %locx% - Bukkit - player - The players location X
    • %locy% - Bukkit - player - The players location Y
    • %locz% - Bukkit - player - The players location Z
    • %iteminhandid% - Bukkit - player - The ID of the item the player has in hand
    • %iteminhand% - Bukkit - player - The item the player has in hand
    • %isop% - Bukkit - player - Is the player an OP - "YES" or "NO"
    • %serveronlinecount% - Bukkit - Number of players currently on server
    • %serverver% - Bukkit - version of the server
    • %groups% - Plugin - Permissions - The list of groups to which the player belongs.
    • %prigroup% - Plugin - Permissions - The first group returned by Permissions to which the player belongs.
    • %helpver% - Plugin - HelpCenter - Version of the plugin
    Colour Codes:


    To use colours, simply add the following codes anywhere in the text file. They will be parsed out and replaced with the proper codes:​

    &0 = black, &8 = black (hi) = dark grey
    &1 = blue (lo), &9 = blue (hi)
    &2 = green (lo), &a = green (hi)
    &3 = cyan (lo), &b = cyan (hi)
    &4 = red (lo), &c = red (hi)
    &5 = magenta (lo), &d = magenta (hi)
    &6 = yellow (lo), &e = yellow (hi)
    &7 = white (lo) = light grey, &f = white (hi)


    Default Helpfile / Random Help Items:
    If you create a file called HelpCenter/HCdefault.txt (case-sensitive) it will display the contents when the player types /help without any parameters. You can also put multiple items, separated by #!HELP (on its own line) and the HelpCenter will randomly select one of the items and display it to the player when they type /help without any parameters. Otherwise, if HCdefault.txt doesn't exist, it will pass-thru the /help command and return the default Minecraft help text.​

    Example HCdefault.txt:

    Code:
    There are many help topics available. Please be more specific?
    #!HELP
    Help me Rhonda!
    #!HELP
    Here's a hint: /help topics
    #!HELP
    I'm sorry Dave, I can't help you.

    Installation:
    1. Copy the file HelpCenter.jar into your plugins folder.​
    2. Run the plugin at least once to create the HelpCenter/ directory.​
    3. Create your help text files as described above.​

    Download:
    Download The Plugin (JAR) v1.78 or..​
    Download The Plugin (ZIP) v1.78​

    Source is at Github ^_^​


    Older Versions (Why you'd want them, I don't know..)​

    Changelog:
    Version 1.78 13-Jun-2011 The_Nut
    • Fixed issue where long line without spaces was not displayed to user in console or ingame and caused the game to crash after a short while.
    Version 1.77 06-Jun-2011 The_Nut
    • Added additional key word replacement:
      %armor% - Bukkit - player - The players armor durability value (0 = none, 20 = full armor not damaged)

      Just a note, if you open up the .jar file you will see the README which is the change log and a player.txt file. The player.txt file is a sample help file with all the keyword replacements so you can see how it works.
    < 1.77:
    Show Spoiler

    Version 1.76 04-Jun-2011 The_Nut
    • Updated to work properly with permissions version 3.0+.
    • Fixed display of message on player login so it has proper line wrapping.
    • Tested and working well on my system CB 803 with permissions 2.7.2
    • Tested and working well on my system CB 818 with permissions 3.1
    Version 1.75 23-May-2011 The_Nut
    • Added more key word replacements (see list above)
    Version 1.73 10-May-2011 The_Nut
    • Add Javadoc, Cleaned up additional code.
    • Allow for HelpCenter to be used in console.
    • Fixed buildHelpFiles and buildPlugin commands to be more robust and consistent in building help files.
    • Added command helpp to pull help file information directly from the server's installed plugins.
    • Cleaned up internal code
    • Fixed line wrapping so it will not count chat color codes as part of the 60 char limit per line.
    Version 1.72c 05-May-2011 The_Nut, weasel5i2

    • Changed the colour codes to fit the accepted standard. I apologise if this broke all of your helpfiles!!
    • Incorporated changes by The_Nut (via Github merge)
    • Recompiled against latest recommended Craftbukkit build #740.
    Version 1.72 30-Mar-2011 weasel5i2

    • Recompiled against latest recommended Craftbukkit build #602.
    Version 1.71 21-Mar-2011 weasel5i2

    • Fixed a minor bug with the colour code parsing
    Version 1.7 18-Mar-2011 weasel5i2

    • Recompiled against latest recommended Craftbukkit build #556.
    • Added line-wrapping functionality for long lines
    Version 1.61 09-Mar-2011

    • Recompiled against latest recommended Craftbukkit build #522.
    • Fixed the CommandSender issues. Sorry about the inconvenience. :)
    Version 1.6 08-Mar-2011

    • HelpCenter folder now moved to plugins/HelpCenter. This should happen automatically. If you have an empty plugins/HelpCenter folder and all your helpfiles are in HelpCenter then simply delete the empty folder plugins/HelpCenter and restart the server and it should move it properly to the new location.
    • Complete rewrite of helpfile content handling.. Now nested help keys URL/HELP work properly (and infinitely, try not to make any infinite helpfile loops! :D)
    • Recompiled against latest recommended Craftbukkit build #493.
    Version 1.5 03-Mar-2011

    • Removed deprecated PLAYER_COMMAND code, replaced with the new onCommand() method.
    • Fixed /? to work the same as /help.
    Version 1.4 27-Feb-2011

    • Recompiled against Craftbukkit build 440
    • Added helpfile redirection capability.
    • Added informative console output error messages.
    • Now sends "No help found for ___." to player if an error occurs (malformed redirector/url formatting, file errors, etc).
    • Removed the need to add a space before the closing ] bracket. Both ways will work now. (e.g.: "[URL http://web.site/help.file]" and "[URL http://web.site/help.file ]" will both work)
    Version 1.31 24-Feb-2011

    • Removed stupidly long constructor and compiled against Craftbukkit build 432
    Version 1.3 15-Feb-2011

    • Fixed bug in which all PLAYER_COMMAND events were being intercepted and mishandled.
    Version 1.2 14-Feb-2011

    • Added colour capability (see codes above).
    • Added default helpfile random item capability per user request.
    Version 1.1 11-Feb-2011

    • Added web-based help fetching capability (see notes above)
    • Removed command case-sensitivity. Filenames must be in lowercase (excepting HCDefault.txt as described above).
    Version 1.0 10-Feb-2011

    • Created plugin.


    To Do:
    • Any suggestions? :)
    Please let me know what you think, if there are any issues or if it doesn't play nicely with the other plugins. It should, though. Also, it doesn't use any super-special classes, just the basic ones, so I'm certain this should work with most earlier versions of CraftBukkit. Suggestions are always welcome.


    --W5i2
     
  2. Offline

    The_Nut

    The following variables can be replaced in your URL request.
    Code:
    %user% - Bukkit - The players name
                           Ex: "The_Nut"
    %groups% - Plugin - Permissions - The list of groups to which the player belongs. This will be surrounded by square brackets.
                           Ex: "[GroupA,GroupB,GroupC]"
    %prigroup% - Plugin - Permissions - The first group returned by Permissions to which the player belongs.
                           Ex: "GroupA"
    %helpver% - Plugin - HelpCenter - Version of the plugin.
                           Ex: "1.74"
    
    NOTE: All spaces " ", periods ".", and slashes "/" will be stripped out of the players name, and group names. The period in the version number will remain.

    URL Example:
    Code:
    http://www.MyFakeSite.com?user=%user%&groups=%groups%&prigroup=%prigroup%&helpver=%helpver%
    
    would become:
    
    http://www.MyFakeSite.com?user=The_Nut&groups=[GroupA,GroupB,GroupC]&prigroup=GroupA&helpver=1.74
    

    So you would like to have the following added to the list:
    Code:
    %world% - Bukkit - The world the player is currently in.
                           Ex: "PVPWorld"
    
    Anything else? (request only, no guarantee) :)
     
  3. Offline

    jamdis

    Wow! I ask, and it's already implemented! You rock!
    URL Example:
    Player's username is really the main thing that I wanted. I don't use multiple worlds myself (yet), so that isn't too big a deal to me personally.

    but Hmmm..... what variables could I use....
    • Player's X,Y & Z coords could be useful for location specific stuff
    • Player's current health
    • id of item in player's hand
    • number of players online
    • Statistics / achievement data?
    I'm sure I could think of more.

    Other thoughts:
    I'm not really using this as a help system. Is it possible to customize the command to something other than "/help" ?

    What if my scripts could return a chat command that would then be executed?

    There's a couple seconds of lag while the page loads (mainly my shitty PHP code's fault I think.) A customizable "loading" message would be cool.

    Thank you so much. This has taken my minecraft experience to a new level.
     
  4. Offline

    The_Nut

    Ok, here is a new version 1.75 I have updated the variables that can be replaced when constructing a URL or HELP redirect or in the help files themselves.
    Code:
    version 1.75 20-May-2011
        * Added more key word replacements: (total list)
          %user%              - Bukkit - player - The players name
          %world%             - Bukkit - player - The world the player is in
          %health%            - Bukkit - player - The players health value (0 = dead, 20 = full health)
          %locx%              - Bukkit - player - The players location X
          %locy%              - Bukkit - player - The players location Y
          %locz%              - Bukkit - player - The players location Z
          %iteminhandid%      - Bukkit - player - The ID of the item the player has in hand
          %iteminhand%        - Bukkit - player - The item the player has in hand
          %isop%              - Bukkit - player - Is the player an OP - "YES" or "NO"
          %serveronlinecount% - bukkit - Number of players currently on server
          %serverver%         - bukkit - version of the server
          %groups%            - Plugin - Permissions - The list of groups to which the player belongs.
          %prigroup%          - Plugin - Permissions - The first group returned by Permissions to which the player belongs.
          %helpver%           - Plugin - HelpCenter  - Version of the plugin
    
    I could not find any hook into getting the statistics/achievements for the player as that is stored on the client side. (as far as I can tell)

    HelpCenter v1.75 download link This has been tested on RB 740 - RB 803 and works for me.

    If you open up the .jar file, you will see a file called player.txt that you could copy to your plugins/HelpCenter/ directory. Then issue the /help player to see an example of all the replacement examples in one file.

    This is not something I will program directly into the plugin since it is used by more than you and I. BUT you can do it yourself easily. Steps to do this.
    Using a zip program of some kind like 7-zip to open up the jar file. Edit the plugin.yml file inside. Edit the line
    aliases: ['?']
    and change it to
    aliases: ['?','somethingelse']
    and then save it back into the jar file and reload/restart the server.
    This will allow you to continue to use the /help and the /? while also using /somethingelse. Please only add to the aliases line as changing the others could lead to issues.

    Interesting thought... Hmm.. Suggestions? (again, I have not looked into doing this, so nothing guaranteed. :)

    Sorry for not being able to update the OP... Will work on that later with Weasel
     
  5. Offline

    lacroserocks

    1.73 worked fine for me on Windows 7 server, however, i just switched over to Ubuntu linux. Basically all I did was copy my server folder and create a StartServer.sh script.

    There is 1 problem. The welcome.txt text shows up fine when I login, but when I use /help, it says "nonexistent help file" even though I have HCdefault.txt in the HelpCenter folder. I tried all my other help files that I had made, but none of them work. any suggestions?

    EDIT: seemed to have fixed this problem. apparently linux doesnt like "HCdefault.txt" and prefers "hcdefault.txt" -_-
     
  6. Offline

    The_Nut

    linux is case sensitive in its filenames. I believe I have lowercased all the path\filenames before i search for them. Sorry about not stating that explicitly.
     
  7. Offline

    jamdis

    Thanks! I can't wait to start reading twitter updates from my MC world.

    -J
     
  8. Offline

    cholo71796

    This is a great plugin, but when the text wraps it reverts to white. Also, the indentation doesn't seem to be working properly. When I do this:
    Code:
    &bProtection help:
     &6By joining a faction, you are instantly granted the &6ability to build anywhere in its territory. &aTraders&6 are &6also able to build in the &atrade districts&6 of other &6factions. Griefing is not allowed, will be punished and &6rolled back using &aBigBrother&6.
     &6The server uses the &aLWC&6 and &aPreciousStones&6 plugins. &aLWC&6 &6protects any container, door or sign using commands. To see &6those commands, reference:
      &a/lwc
     &aPreciousStones&6 is used only by the &8Wild&6 faction. By &6placing &agold blocks&6, &8Wild&6 protect a 9-by-9-by-4 block zone &6to prevent griefing.
    I get the LWC bit indented, but the paragraphs are not. I tried using multiple spaces to no avail. It seems that the plugin is picking on me. Am I making some sort of fake spaces? I cannot find any logic behind this.
     
  9. Offline

    The_Nut

    I am sure the plugin in picking just on you. ;) I think there is code in there that searches just for your name.
    Code:
      if (playerName = "cholo71796") { randomize string to bug him.}
    
    Kidding aside... This is the first time I have looked at the line wrap code. Here are the rules that it follows.
    Code:
      1) if a line (with color codes stripped off) is less than 60 characters long, it is displayed without modification.
      2) if a line (with color codes stripped off) is greater than 60 characters then the following happens:
        2a) The line is split into words on spaces (thus the spaces are lost, but the color codes are kept with the word).
        2b) The words are put back together (separated by a space) until the line is as close to 60 characters as possible.
                NOTE: the color codes do not count towards the 60 character limit
        2c) if a word will make the new line greater than 60 characters, a new line is created starting with the current word.
    
    The above is repeated for each line in the file read from disk or returned from a URL.
    Each line in the client defaults to white unless there is a color code to change it.

    A work around you can do to keep all formatting until this gets adjusted is to keep each line of your help file to less than 60 characters. (not including the color codes) This will bypass the line wrapping code. Remember that each new line defaults to white, so you will have to put a color code where needed.

    Hopefully this helps in understanding why the spacing is off for you.
    I will find some time to try and rework this to have the color coding continue on a wrapped line and preserve more of the original spacing.
     
    weasel5i2 likes this.
  10. Offline

    Pontus Lantz

    In Craftbukkit 812 The plugin is Enabled and no errors appear but /help command is standard bukkit instead of HelpCenter standard.
     
  11. Offline

    The_Nut

    Ever since I have started helping with this plugin, i have always understood it to be a drop in replacement for the help system. So yes, the /help command has been a bukkit standard for a long time. if you want the base /help command to work as normal, but want the functionality of this plugin under a different command, do the following:
    open the .jar file
    Edit plugin.yml
    change the "help" command word to something else.
    save the yml file back into the .jar
    reload server.
    :)

    otherwise, I feel this plugin does exactly what it is supposed to, and very well.

    Thanks for the craftbukkit 812 note on it working.
     
  12. Offline

    Pontus Lantz

    @The_Nut
    What i meant was that in 812 the plugin doesn't work. It says enabled and all but when i write /help it shows all commands instead of HelpCenter's files.
     
  13. Offline

    The_Nut

    I had CB 803 and it was working fine. I downloaded and installed the 812 and when I typed /help, it showed the contents of my hcdefault.txt file. So I am not sure why it is not working on your end.

    My plugin structure is as follows.
    Code:
    Bukkit/
        Plugins/
            HelpCenter/
                helpcenter/
                    buildHelpFiles
                    buildPlugin
                    help
                    helpp
                hcdefault.txt
                helpcenter.txt
                (additional .txt files for each of my plugins)
                (additional directories for each of my plugins)
    
            HelpCenter.jar    (version 1.75)
            (additional plugins)
            (additional directories for my plugin configs)
    
    Let me know if there is anything else I can do to try and help.
    Could it be another one of your plugins that is changing things?
     
  14. Offline

    jmcneely

    Got the new recommended build (818) and upon logging in, I get this error on the server console:
    Code:
    10:00:43 [SEVERE] Could not pass event PLAYER_JOIN to HelpCenter
    java.lang.NullPointerException
            at com.nijiko.permissions.Control.getGroups(Control.java:620)
            at net.weasel.HelpCenter.HelpCenter.doStringTokenReplacements(HelpCenter
    .java:571)
            at net.weasel.HelpCenter.HelpCenter.getHelpFile(HelpCenter.java:239)
            at net.weasel.HelpCenter.HelpCenterListener.onPlayerJoin(HelpCenterListe
    ner.java:26)
            at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:243)
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.jav
    a:58)
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.j
    ava:310)
            at net.minecraft.server.ServerConfigurationManager.c(ServerConfiguration
    Manager.java:123)
            at net.minecraft.server.NetLoginHandler.b(NetLoginHandler.java:96)
            at net.minecraft.server.NetLoginHandler.a(NetLoginHandler.java:33)
            at net.minecraft.server.NetworkListenThread.a(SourceFile:91)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:401)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:311)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    EDIT: Nevermind, it was my fault. I had switch to a temporary map and when I switched back I forgot to change the permission's file name.
     
  15. Offline

    Pontus Lantz

    @The_Nut
    Code:
    Bukkit/
        Plugins/
            HelpCenter/
                hcdefault.txt
                helpcenter.txt
                (additional .txt files for each of my plugins)
                (additional directories for each of my plugins)
                (alot of other homemade .txt)
    
            HelpCenter.jar    (version 1.75)
            (additional plugins)
            (additional directories for my plugin configs)
    Thats how mine is. Haven't changed anything at all. Will try changing all to your setup now.
    All i did to make it stop working was updating from 803 to 812.

    EDIT: Removed the whole HelpCenter map in /Plugins. Still not functioning. /help just shows all commands and writes
    "22:51:55 [INFO] §9[PLAYER_COMMAND] Qboll: /help"
    in the server log. welcome.txt is still showed at login.
     
  16. Offline

    The_Nut

    Did you by chance upgrade Permissions to 3.0 or 3.1. I found that to cause an error on my end.
    I have updated the plugin. See next post for link.

    HelpCenter Update to 1.76
    * Updated to work properly with permissions version 3.0+.
    * Fixed display of message on player login so it has proper line wrapping.

    * Tested and working well on my system CB 803 with permissions 2.7.2
    * Tested and working well on my system CB 818 with permissions 3.1

    HelpCenter 1.76 Download Link

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 8, 2016
  17. Offline

    jmcneely

    Thanks for the update! And thanks for fixing the welcome message bug, it doesn't look like crap when I login anymore.
     
  18. Offline

    The_Nut

    @jmcneely
    You are very welcome.

    And now for another update. Sorry for the rapid fire release on this one.
    Just figured out how to do this after I released the previous one, so I am adding it. (Thanks to the dynmap server plugin from which I borrowed to figure this out)

    HelpCenter Update to 1.77
    * Added additional key word replacement:
    %armor% - Bukkit - player - The players armor durability value (0 = none, 20 = full armor not damaged)

    Just a note, if you open up the .jar file you will see the README which is the change log and a player.txt file. The player.txt file is a sample help file with all the keyword replacements so you can see how it works.

    HelpCenter 1.77 Download Link

    TODO (when I have time):
    - fix wrapping a long line loosing the specified color tag and resets to white. (hard returns in the source file will always default to white as it currently does)
     
  19. Offline

    jmcneely

    Hahaha its ok today is my update day, I go through and check if there is updates for the plugins I use. I am a bit confused about the new feature but my mind is stressed out from all the updating(mainly with updating to the new permissions). Might make sense when I come back and read it.
     
  20. Offline

    The_Nut

    The easiest way to see what the update does, is to open up the jar file and copy out the player.txt file and place that in the plugins/HelpCenter directory. Then in game, type "/help player" to see an example of the replacements. The replacements were a request for someone wanting to be able to put them in a URL request so it would hit his web server for the information.
     
  21. Offline

    jmcneely

    I'll try that once I get home, but i reread it and I think I understand and i can see this very useful. These key words can be used in any text file aside from player.txt right?
     
  22. Offline

    The_Nut

    Correct.

    They can be used in any of the HelpCenter text files and in the [URL address] and [help alternateFile] redirects to help build what to redirect to.
     
  23. Offline

    jmcneely

    For some reason %groups% duplicates, it shows the groups twice. Might be something with the new permissions as it now has globe groups/users files along with the regular world groups/users. Other then that, everything is working as it should for me and I am really enjoying the new features.
     
  24. Offline

    Lycius

    I'm no plugin developer, so I have no idea how to do this. I want to make it so OPs see a different /help than normal players. I think you've implemented this, but I don't know how to do it. I think you posted something about it earlier, and I understand it, but I don't know where to put it. Should it go in a file in the help commands folder? Or in plugin.yml? What?
     
  25. Offline

    The_Nut

    @Lycius
    I will try to explain this by giving a specific example. The following is the order that is tried when searching for the "welcome" file when a player logs in or when a player types "/help welcome". This example also assumes that the player's primary group in permissions is called "Admin".

    Code:
    plugins\
      HelpCenter\
        Admin\
          welcome       (2) Primary group directory, without replacing spaces with "/"
          welcome.txt   (1) Primary group directory, .txt on end, without replacing spaces with "/"
        welcome         (4) without replacing spaces with "/"
        welcome.txt     (3) .txt on end, without replacing spaces with "/"
    
    If the player types "/help manage player" and who's primary group in permissions is called "Admin".
    Code:
    plugins\
      HelpCenter\
        admin\
          manage\
            player            (4) Primary group directory, with replacing spaces with "/"
            player.txt        (3) Primary group directory, .txt on end, with replacing spaces with "/"
          manage player       (2) Primary group directory, without replacing spaces with "/"
          manage player.txt   (1) Primary group directory, .txt on end, without replacing spaces with "/"
        manage\
          player              (8) with replacing spaces with "/"
          player.txt          (7) .txt on end, with replacing spaces with "/"
        manage player         (6) without replacing spaces with "/"
        manage player.txt     (5) .txt on end, without replacing spaces with "/"
    
    In both of these examples, the file to display is searched in order from 1 to 8 in order and the first one found will be processed for display.

    When the file is processed, first the %xxx% tokens will be replaced with the appropriate values.
    If a line in the file is of the structure of [URL address] the appropriate address will be retrieved and displayed.
    If a line in the file is of the structure of [file alternatefile] the appropriate file will be retrieved using the same search pattern above.

    You asked about having a special directory for OPs. That gets more tricky as that flag is not in the search parameters. Sorry. But if you use permissioins, you could have a separate help file version per group (default, player, admin, SuperAdmin, etc.) by making a separate directory for each one and build a structure under that.

    Hope this long explanation helps you understand where to put your files. The directory structure can be as deep as needed, but each directory name will have to be typed by the player or be part of their primary group name.

    regards,
    The_Nut
     
  26. Offline

    Lycius

    Oh, I understand now. I didn't realize the
    Code:
    plugins\
       HelpCenter\
          admin\
    was the directory. I thought there should be a file that directs normal players to the normal help message, and admins to the admin help message. Well, if I had realized that earlier, this would have been a lot easier. Thanks for the explanation.
     
  27. Offline

    The_Nut

    You are welcome, just remember the "admin\" directory would be the name of whatever their primary permissions group they belong to. :)
     
  28. Offline

    Lildirt

    My only problem with this plugin is that, when I go to the next line on the .txt is that it doesn't do the same. It doesnt make a space, it does nothing. It acts like as if I just typed it out such as "Welcome to MultiCraft!Apply for building rights at: [link]."
    Its mashing them together, when it should go down to another line.
    Is this how it is supposed to act? :(
     
  29. Offline

    The_Nut

    That was an issue that was previously fixed in an update to 1.76 as mentioned on the previous page.

     
  30. Offline

    jmcneely

    I am having a weird problem. I have news.txt so people can get URLs to websites to give players news, photos, and other things about the server. But the URL to the minecraft forum page doesn't show at all and shortly causes the server to stop responding. The URL is http://www.minecraftforum.net/topic/104621-venture-industries whats odd is that the second URL works perfectly fine.
     
  31. Offline

    The_Nut

    can you PM me the help file that contains the [URL address] line in it, or post it here so I can try to see what is causing it. I will be busy the rest of the week and will try to get to it soon.
     

Share This Page