[CHAT/ADMN] OKChat v3.0.7 - It only does everything chat-related! [1.0.0-R1]

Discussion in 'Inactive/Unsupported Plugins' started by Kalman Olah, Jul 26, 2011.

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

    Kalman Olah

    OC - OKChat
    by Kalman Olah​
    Latest version: 3.0.7 ( Download )​
    Would you like to buy me a drink? some useless stuff from Amazon? a car?​
    [​IMG]
    What is OKChat?
    OKChat is twenty plugins in one. If it's chat related, it can do it.

    OKChat supports Permissions, PermissionsEX, bPermissions and PermissionsBukkit.
    Where can I download OKChat?
    The latest version of OKChat can always be found here.
    Additionally, OKChat comes with an auto-updater which will download updates to the /plugins/OKChat/update/ folder.
    How do I set up OKChat?
    After you've extracted the .jar to your server's /plugins/ directory and have restarted your server OKChat will generate a config.yml file, which can be found in the /plugins/OKChat/ directory.
    This configuration file is fully commented and should be easy to understand for anyone.​
    How do I use OKChat?
    OKChat commands:​
    OKChat permissions:
    Misc:
    Check out OKChat on Github!

    Changelog:
    Version 3.0.7
    • Attempted fix for "StringOutOfBoundsException". This is a java bug. Screw you, replaceAll.
    Version 3.0.6​
    • Fixed player list formatting. Turns out I had disabled it. Why? No idea.
    Show Spoiler
    Show Spoiler

    Version 3.0.5​
    • Added the config boolean "general.strip-log-color" to strip all color from logged chat. This feature sure is extremely useful.
    Version 3.0.4​
    • Priority overhaul to fix compatability with other plugins such as xAuth, modifyworld, mcMMO, etc...
    Version 3.0.3​
    • Fixed not being able to whisper players with an underscore in their names. I forgot you could use underscores...
    Version 3.0.2​
    • Fixed local chat not showing up to the player chatting.
    • Added console logging of chat.
    Version 3.0.1​
    • Added %time% variable. You can configure the format in "general.time-format".
    • Added "okchat.chatcolor" node. Guess what it does? Won't work well with word wrapping, due to the way it splits long chat messages into multiple messages.
    Version 3.0.0​
    • Complete recode. Added a lot of features. Check the config and you'll understand.
    Version 2.2.1​
    • Made %currentplrs% and %maxplrs% usable in more messages.
    Version 2.2.0​
    • Added optional logging of PMs/replies. Check the example config to see what key you need to add, or OKChat will not work if you do not delete your configuration first.
    Version 2.1.3​
    • Setting join,quit,kick messages to "default" will cause them to remain unaltered. Setting them to empty values, or removing them from your config file will result in the message being removed completely.
    Version 2.1.2​
    • Important bugfix.
    Version 2.1.1​
    • Ignored deprecation warnings. Thanks bukkit!
    Version 2.1.0​
    • Added /who <world>. Lets you see players in <world>. Node: okchat.whoworld
    • Added /dnd <message>. It's like /dnd, but your custom message is also shown to the player whispering you.
    Version 2.0.2​
    • Tablist names are now set 5 seconds after login.
    Version 2.0.1​
    • Updated for 1240.
    Version 2.0.0​
    • Added /who command.
    • Added motd.
    • Added "TAB" player list formatting.
    • Added the ability to use color codes with signs.
    • Misc additions and rewrites.
    • Added compatability with GroupManager.
    • Added compatability with bPermissions.
    Version 1.5.0​
    • Compressed code.
    • Added hooks for future handlers for persistent pms.
    • Added anonymous stat sending option.
    Version 1.4.2​
    • Added /m to the incredibly large list of /w aliases.
    Version 1.4.1​
    • Added the /afk command. Node: okchat.afk.
    • Added the "%status%" formatting variable. If a user has DND turned on, it will be <DND>. If a user has AFK turned on, it will be <AFK>. DND takes priority over AFK. This can be coloured and used in all chat formats, including DND, ignore, regular chat, whispers and the like.
    Version 1.4.0​
    • Added Persistent messaging along with the /pm command. /pm <target> <message> will send someone a message, and any further regular chat will be sent to this player, as a message. /pm clears this status.
    Version 1.3.3​
    • Fixed a bug where the DND status wouldn't work if you were ignoring someone.
    Version 1.3.2​
    • Added the weight value for chat formats. If a player has 2 format permissions nodes, the format with the highest config.yml weight value will be used.
    Version 1.3.1​
    • Fixed a bug with replies.
    Version 1.3.0​
    • Added an ignore system. This ignore list is reset when you log out or get kicked.
    • Added a DND system. This mode is reset when you log out or get kicked.
    • Made OKChat use commands /w,/whisper,/r,/re,/reply,/msg,/message,/tell,/respond...because I can.
    • Added customizable whisper, reply, ignore, emote, DND message formats in the config.yml.
    Version 1.2.2​
    • Changed /r to /re to avoid certain bugs.
    Version 1.2.1​
    • You can now disable custom join/kick/quit messages by simply removing the value from your config file.
    Version 1.2.0​
    • Added custom join, leave and kick messages. Thanks to @Asphodan for the suggestion.
    Version 1.1.8​
    • The displayname is now displayed when you use /me.
    Version 1.1.7​
    • Attempted message color bugfix.
    Version 1.1.6​
    • Fixed a bug that caused color codes in prefixes/suffix not to be parsed.
    Version 1.1.5​
    • Removed SuperPerms support again.
    Version 1.1.4​
    • Added SuperPerms support.
    • Added bInfo (prefixes/suffixes for superperms) support.
    • Added the %suffix% variable.
    Version 1.1.3​
    • Hotfix to fix an issue where the plugin crashed when the auto-update server was down.
    Version 1.1.2​
    • Fixed a bug that caused OKChat to throw errors when no prefix was set.
    Version 1.1.1​
    • Added the %prefix% format variable. This gets a player's permissions group/user prefix.
    Version 1.1.0​
    • Added the 'okchat.color' permission node. If you have this node, you can use the &1 - &9 and &a - &f color codes in chat.
    • Added the 'okchat.emote' permission node. If you have this node, you can use the /me <message> command to broadcast an action. I think it looks pretty neat too, to be honest.
    • Added the 'okchat.whisper' and 'okchat.reply' permission nodes. If you have these nodes, you can use the /w <target> <message> and /r <message> commands to send and reply to messages.
    Version 1.0.2​
    • Removed a debugging value I forgot to remove.
    • Changed the plugin so the actual chat message remains unaltered. This should make sure OKChat doesn't cause issues with stuff like Dynmap.
    Version 1.0.1​
    • Improvements.
    Version 1.0.0​
    • Initial release.
     
    minechomp, zecheesy and mruczek like this.
  2. Offline

    Euthyphro

    It's almost a "few days" into the new year, can't wait to see OKChat 3.0.0 launched!
     
  3. Offline

    scuba2dan

    Thanks for this awesome plugin.

    Worked straight out of the box with no faff!

    Now to see what else I can replace with OK plugins :)
     
  4. Offline

    Euthyphro

    Just sent you a small gift via donation, will send more once you get v3.0.0 out. :)
     
  5. Offline

    Kalman Olah

    3.0.0 is out!
    What's new? A lot!

    The config is commented pretty heavily, so you should be able to figure out how to use it.

    If I forgot to add any suggestions, feel free to ask again. I either had a good reason for leaving it out, or I forgot.

    Thanks :)
     
  6. Offline

    Snear

    I was just downloading this last night, but the download seemed to be down.
    Great timing, now I can download 3.0.0 :D

    Edit: Is there a way to completely disable channels? I have read over the config a few times and there doesn't seem to be a way to disable them. I'm trying to put a rank before someone's name:
    [Default]Snear: example
    Do I need to make a channel for each group?
     
  7. Offline

    Nick Hooper

    Love the new style, very complex but super easy to understand. Wasn't hard to migrate :D. Would it be possible to have different prefix/suffix's per channel? My idea was to have Guild channels in which they had there own ranks so when you talk in your guild chat channel it shows your guild rank or prefix/suffix instead of the global chat "Guest/Member/Admin..etc"
     
  8. Offline

    Kalman Olah

    No mate. Just make one channel, call it "global", set its config to "global: true", and the format to "%prefix%%displayname%&7: &f%message%" or something. :)

    Sorry mate, don't think I'll add that =/.

    Oh. I completely forgot to mention that whispers and replies now work like this:
    Code:
    @Player hey how's it going?
    This sends "Player" a message saying "hey how's it going?"
    @ pretty good, you?
    This replies to the last person who whispered you saying "pretty good, you?"
    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 18, 2016
  9. Offline

    melkerboom

    wow so much to read
     
  10. Offline

    seriosbrad

    Damn, 3.0 is big. Good job, gonna start a new config now haha.
     
  11. Offline

    minechomp

    Why did you remove name coloring from 3.0? Other than that nice job. Can't update it though because it doesn't support name coloring.
     
  12. Offline

    seriosbrad

    What do you mean? Use prefixes, works for me.
     
  13. Offline

    Kalman Olah

    I think he means the multiple formats.

    I removed multiple formats because having both that and multiple channels would be a bit too much.
    If you really need colored chat, use prefixes and %prefix%. OKChat 3.x.x includes a custom prefix system for people whose permissions plugins don't have prefixes.
    Haha, yup!
    Yup. I can assure you: it was quite a pain.
     
  14. Offline

    Wiinick

    1 thing it cant do, if there is a global channel and a local channel, doing /g msg wont speak in global if ur in local.

    So add
    -local with set radius of how far ppl can hear you
    -make a global channel
    -make a quick global channel with /g msg
     
  15. Offline

    Kalman Olah

    Taken straight from the config.yml:
    Code:
        # Configure the channels here.
        channels:
            # Name of the channel.
            ExampleChannel:
                # The chat format for the channel.
                format: '&7[&b%channel%&7] &f%prefix%%displayname%&7: &f%message%'
                # Is the chat global?
                global: true
                # Is the chat world-based?
                world: false
                # Is the chat local?
                local: false
                # (optional) Range of local chat
                range: 15
                # Does this channel require 'okchat.channel.<name>' to join?
                protected: false
                # Are you allowed to unsubscribe from this channel?
                unsubscribe: true
    Want a local channel with only people 20 blocks around you hearing you?
    Code:
        # Configure the channels here.
        channels:
            # Name of the channel.
            Local:
                # The chat format for the channel.
                format: '&7[&b%channel%&7] &f%prefix%%displayname%&7: &f%message%'
                # Is the chat global?
                global: false
                # Is the chat world-based?
                world: false
                # Is the chat local?
                local: true
                # (optional) Range of local chat
                range: 20
                # Does this channel require 'okchat.channel.<name>' to join?
                protected: false
                # Are you allowed to unsubscribe from this channel?
                unsubscribe: true
    Want a global channel?
    Code:
       # Configure the channels here.
        channels:
            # Name of the channel.
            Global:
                # The chat format for the channel.
                format: '&7[&b%channel%&7] &f%prefix%%displayname%&7: &f%message%'
                # Is the chat global?
                global: true
                # Is the chat world-based?
                world: false
                # Is the chat local?
                local: false
                # (optional) Range of local chat
                range: 15
                # Does this channel require 'okchat.channel.<name>' to join?
                protected: false
                # Are you allowed to unsubscribe from this channel?
                unsubscribe: true
    
    Want a local and a global channel?
    Code:
    # Configure the channels here.
        channels:
            # Name of the channel.
            g:
                # The chat format for the channel.
                format: '&7[&b%channel%&7] &f%prefix%%displayname%&7: &f%message%'
                # Is the chat global?
                global: true
                # Is the chat world-based?
                world: false
                # Is the chat local?
                local: false
                # (optional) Range of local chat
                range: 15
                # Does this channel require 'okchat.channel.<name>' to join?
                protected: false
                # Are you allowed to unsubscribe from this channel?
                unsubscribe: true
            # Name of the channel.
            l:
                # The chat format for the channel.
                format: '&7[&b%channel%&7] &f%prefix%%displayname%&7: &f%message%'
                # Is the chat global?
                global: false
                # Is the chat world-based?
                world: false
                # Is the chat local?
                local: true
                # (optional) Range of local chat
                range: 20
                # Does this channel require 'okchat.channel.<name>' to join?
                protected: false
                # Are you allowed to unsubscribe from this channel?
                 unsubscribe: true
    
    Want to message global while being in local?
    Code:
    /m <channel> <message>
    e.g.:
    /m g Hey guys
     
  16. Offline

    Wiinick

    Wow you have thought of everything BUUUT you NEED to change /m g msg to /g hey guys
     
  17. Offline

    Kalman Olah

    Due to the way channels work(as in: you can pick their names), OKChat will be sticking to "/m <channel> <message>", sorry =/
     
  18. Offline

    Snear

    Yes, I had a feeling you could hide the channel like that :D
    Is there any way you could possibly include support for the Factions plugin. It uses {FACTION} in the format, making for something like:
    {FACTION}%prefix%%displayname%&7: &f%message%
    With OKChat it actually comes up with {FACTION} before the prefix, instead of the actual faction name. Thanks for the help! :D
     
  19. Offline

    Kalman Olah

    Due to the way the built-in word wrapping works, I can't actually add support for Factions tags.
     
  20. Offline

    ieatsofas

    So there is no way to use faction tags in the chat with 3.0.0? Not even if I disable word wrapping?
     
  21. Offline

    mmerner

    Hello (CB1597,PEX 1.17)

    Been using 3.0.0 for past 2 days. Couple things confuse me.

    I created a channel called AC in the config.yml. Initially it was protect: false. then changed to true and added okchat.channel.AC to permissions. still everyone can see the channel AC, after /reload and /okchat reload too. So tried removed the AC chan from the congif.yml, but yet I still can join AC after okchat-reload.

    I made AC2 , made it protected:true before okchat-reload and it is protected correctly.


    It would be nice to see a channel list. and who is on what channels.

    thanks
     
  22. Offline

    Kalman Olah

    Any with okchat.channel.<name> will be able to join the channel if it's protected. People WITHOUT the permission won't be able to join.
     
  23. Offline

    seriosbrad

    It doesn't seem like color codes are parsed in the %message%, can we get support for that? Since it works with pretty much anything else including signs :p

    And with permissions support? (okchat.chatcolor?)
     
  24. Offline

    Bleaker

    Been using OKChat for a while, I love it and am very pleased with 3.0. However, I'm missing the %time% format; has it been removed entirely, or hopefully just renamed? It's a code I really enjoyed and would like to use again.

    Thanks again :)
     
  25. Offline

    2Bucks

    Could you add a configurable chat cooldown option? I'd like to have a 10-15 second chat cooldown in the global chat to prevent massive spamming.
     
  26. Offline

    ieatsofas

    So the configurable chat format permission nodes are gone? Is it only prefixes now?
     
  27. Offline

    Kalman Olah

    Version 3.0.1
    • Added %time% variable. You can configure the format in "general.time-format".
    • Added "okchat.chatcolor" node. Guess what it does? Won't work well with word wrapping, due to the way it splits long chat messages into multiple messages.

    Sure. It won't work well with word wrapping and long chat messages though, I'm afraid.
    Have a cookie.

    Well, OKChat now includes a built-in prefix/suffix system in case your permissions plugin doesn't support them :).
    Plus, there's channels now.
    Uhhh.... no?
    OKChat features the best anti-spam solution known to man. I'm sure you could configure that to stop massive spamming :).

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 18, 2016
    seriosbrad likes this.
  28. Offline

    2Bucks

    I'm a bit confused as to how the anti spam works, particularly this part of the config

    # How many actions can a player perform before protection kicks in?
    actions: 30

    Does that mean like if a player tries to chat 30 times total? Or 30 times per second?
     
  29. Offline

    Bleaker

    Awesome! You are a boss.

    Quick question: Is there a possibility to add a 'time-format'-like line in the config? I typically just use HH:mm with no second colon for seconds, and was wondering if it was possible to have something like that available in this version as well.

    Keep up the good work, dude.
     
  30. Offline

    Kalman Olah

    30 times per minute.
    It's already there. If you let OKChat 3.0.1 remake your config, it'll be at the top.
    e.g.:
    Code:
    general:
        time-format: 'HH:mm'
     
  31. Offline

    Euthyphro

    1) There seems to be a problem with the formatting for longer messages, if your message length is longer than 1 line, your plugin now splits it across three lines:
    okchatglitch.jpg

    2) Another glitch to report is that when an admin types /ignore playername, it mutes them from global chat so no one can see.

    3) /nick with multicolours works but gets cut off. For example, if you type /nick &4E&5u&6t&9h&ay&bp&ch&dr&eo , unfortunately the last letter of my name gets cut off. I think perhaps you might have some check for max nick or something, however with the color codes it is causing names to be cut off.


    4) One more glitch, or maybe this was intentionally done, but chat no longer shows up in console. It would be nice to have this back in console for logging purposes.

    5) More glitches, for example typing "/gamemode Euthyphro 1" results in MASSIVE error read out. There are a lot of glitches with this plugin now. Hopefully you can fix them soon. :)

    Massive error read out after using op command: http://pastebin.com/0e0xGfGD

    6) More massive error read outs when typing /m Euthyphro or any other player name to whisper. http://pastebin.com/D59cxB3C

    And another glitch causing huge error read outs in console:
    Code:
    2012-01-07 00:26:19 [SEVERE] Could not pass event PLAYER_COMMAND_PREPROCESS to OKChat
    java.lang.StackOverflowError
        at java.lang.System.checkKey(System.java:789)
        at java.lang.System.getProperty(System.java:666)
        at sun.security.action.GetPropertyAction.run(GetPropertyAction.java:84)
        at sun.security.action.GetPropertyAction.run(GetPropertyAction.java:49)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.io.PrintWriter.<init>(PrintWriter.java:95)
        at java.io.PrintWriter.<init>(PrintWriter.java:79)
        at org.bukkit.craftbukkit.util.ShortConsoleLogFormatter.format(ShortConsoleLogFormatter.java:54)
        at java.util.logging.StreamHandler.publish(StreamHandler.java:196)
        at java.util.logging.ConsoleHandler.publish(ConsoleHandler.java:105)
        at java.util.logging.Logger.log(Logger.java:476)
        at java.util.logging.Logger.doLog(Logger.java:498)
        at java.util.logging.Logger.log(Logger.java:587)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:359)
        at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:749)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:721)
        at org.bukkit.craftbukkit.entity.CraftPlayer.chat(CraftPlayer.java:193)
        at net.kalmanolah.okchat.OKNickNames.handleCommandNickNames(OKNickNames.java:78)
        at net.kalmanolah.okchat.OKPlayerListener.onPlayerCommandPreprocess(OKPlayerListener.java:43)
        at org.bukkit.plugin.java.JavaPluginLoader$5.execute(JavaPluginLoader.java:288)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:339)
        at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:749)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:721)
        at org.bukkit.craftbukkit.entity.CraftPlayer.chat(CraftPlayer.java:193)
        at net.kalmanolah.okchat.OKNickNames.handleCommandNickNames(OKNickNames.java:78)
        at net.kalmanolah.okchat.OKPlayerListener.onPlayerCommandPreprocess(OKPlayerListener.java:43)
        at org.bukkit.plugin.java.JavaPluginLoader$5.execute(JavaPluginLoader.java:288)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:339)
        at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:749)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:721)
        at org.bukkit.craftbukkit.entity.CraftPlayer.chat(CraftPlayer.java:193)
        at net.kalmanolah.okchat.OKNickNames.handleCommandNickNames(OKNickNames.java:78)
        at net.kalmanolah.okchat.OKPlayerListener.onPlayerCommandPreprocess(OKPlayerListener.java:43)
        at org.bukkit.plugin.java.JavaPluginLoader$5.execute(JavaPluginLoader.java:288)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:339)
        at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:749)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:721)
        at org.bukkit.craftbukkit.entity.CraftPlayer.chat(CraftPlayer.java:193)
        at net.kalmanolah.okchat.OKNickNames.handleCommandNickNames(OKNickNames.java:78)
        at net.kalmanolah.okchat.OKPlayerListener.onPlayerCommandPreprocess(OKPlayerListener.java:43)
        at org.bukkit.plugin.java.JavaPluginLoader$5.execute(JavaPluginLoader.java:288)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:339)
        at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:749)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:721)
    
    This error also seems to appear quite frequently:
    Code:
    2012-01-07 01:15:40 [SEVERE] Could not pass event PLAYER_CHAT to OKChat
    java.lang.StringIndexOutOfBoundsException: String index out of range: 2
        at java.lang.String.charAt(String.java:694)
        at java.util.regex.Matcher.appendReplacement(Matcher.java:716)
        at java.util.regex.Matcher.replaceAll(Matcher.java:823)
        at java.lang.String.replaceAll(String.java:2201)
        at net.kalmanolah.okchat.OKChannels.handleChatMessage(OKChannels.java:153)
        at net.kalmanolah.okchat.OKChatHandler.handleChatMessage(OKChatHandler.java:28)
        at net.kalmanolah.okchat.OKPlayerListener.onPlayerChat(OKPlayerListener.java:39)
        at org.bukkit.plugin.java.JavaPluginLoader$6.execute(JavaPluginLoader.java:295)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:339)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:726)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:714)
        at org.getspout.spout.SpoutNetServerHandler.a(SpoutNetServerHandler.java:179)
        at net.minecraft.server.Packet3Chat.a(Packet3Chat.java:33)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:92)
        at org.getspout.spout.SpoutNetServerHandler.a(SpoutNetServerHandler.java:546)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:108)
        at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:516)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:414)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:457)
    Thanks for releasing, more comments/suggestions to come shortly.
     
Thread Status:
Not open for further replies.

Share This Page