Inactive [ADMN] MessageChanger v1.01 - Change the server's default messages [953]

Discussion in 'Inactive/Unsupported Plugins' started by FrozenBrain, Apr 17, 2011.

  1. Offline

    FrozenBrain

    MessageChanger - Change the server's default messages
    Version: v1.01
    CraftBukkit Build: 953


    [​IMG]

    This simple plugin allows you to change the server's default messages to whatever you want.

    Features:
    • Change the server's default messages
    • Use different messages for different worlds, groups and users
    Download MessageChanger v1.01
    Source Code
    [​IMG]

    Configuration:
    Show Spoiler

    MessageChanger 1.00+ works side-by-side with Permissions 3. That means, that you'll have to add some keys to your permissions files.

    Example (groups.yml):
    Code:
        Default:
            default: true
            info:
                prefix: ''
                suffix: ''
                build: false
                messageChanger:
                    KICK_KICK_REASON: '&4Pwned by admin'
                    KICK_FULL: '&eThe server is full, sorry.'
            inheritance:
    Easy as that. Just add a new node called "messageChanger" as a child of the "info" node of either a group or a player. Then add the following keys as childs of the new node:
    Code:
    Key			+ You get the message if ...
    ------------------------+-----------------------------------------------------------
    KICK_FULL		+ The server is full.
    KICK_WHITELIST		+ you're not white-listed.
    KICK_KICK_LEAVEMSG	+ you get kicked (everybody can see this in the chat).
    KICK_KICK_REASON	+ you get kicked.
    PLAYER_JOIN		+ you join the server (everybody can see this in the chat).
    PLAYER_QUIT		+ you leave the server (everybody can see this in the chat).
    KICK_BANNED		+ you're banned from the server.
    SERVER_STOP		+ the server is shutting down (use '' or '%msg' for the usual error message).
    If you need help, feel free to ask :)

    Wildcards:
    %pName - the player's name
    %msg - the original message

    If you want to use colors, use the color codes &0 - &f (click me).


    Todo:
    • Add support for multiple colors - Done!
    • Different messages per group - Done!
    • Stop sending an error to the clients when stopping the server (send a custom message instead) - Done and fixed!
    • Add more wildcards (request some :) )
    Changelog:
    Version 1.01
    • Fixed an NPE
    Version 1.00
    • MessageChanger is now working side-by-side with Permissions 3
      • You have to reconfigure the plugin, read the "Configuration" part above!
    Show Spoiler

    Version 0.24
    • Updated for Minecraft 1.6.6 (CraftBukkit b818)
    • SERVER_STOP is now working correctly, yey!
    Version 0.23
    • Added support for other chat related plugins (needs testing)
    • Updated for CB 803
    Version 0.22
    • Fixed PLAYER_QUIT
    • Updated for CB 733
    Version 0.21
    • Added SERVER_STOP
    Version 0.20
    • Multiworld support
    • Permissions support
    • Added the '%msg' wildcard (see above)
    Version 0.12
    • Added support for colored messages
    Version 0.11
    • Remove messages completely (simply by setting them to '')
    Version 0.1
    • First public release

    Have fun :)
     
  2. Offline

    FrozenBrain

    You should get kicked with the SERVER_STOP message. That's a known bug but I can't do much about it.

    I guess that's also impossible since there's no event for that. But I'll see what I can do.
     
  3. Offline

    TH3steven

    Awesome plugin ;)

    But, when I type /reload ingame, everyone gets kicked.
     
  4. Offline

    FrozenBrain

    That's a known bug. The plugin can't check if the server stops or just reloads the plugins. If you want to prevent the plugin from kicking people, set SERVER_STOP to '' (nothing).
     
  5. Offline

    TH3steven

    ok, thanks ;)
     
  6. Offline

    Taranis01

    @FrozenBrain

    i wanna suggest a Support for StealthLogin ( http://forums.bukkit.org/threads/admin-sec-stealthlogin-v1-1-1-hide-your-joins-and-quits-803.10906/ )
    It works together, but im getting an error message from MessageChanger

    Code:
    > 14:23:31 [INFO] Player "Tara" quitted!
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:394)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:287)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:372)
    at net.minecraft.server.NetworkListenThread.a(SourceFile:100)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
    at net.minecraft.server.NetworkManager.a(NetworkManager.java:200)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:581)
    at net.minecraft.server.ServerConfigurationManager.disconnect(ServerConfigurationManager.java:115)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:289)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:59)
    at org.bukkit.plugin.java.JavaPluginLoader$2.execute(JavaPluginLoader.java:238)
    at de.frozenbrain.MessageChanger.mcPlayerListener.onPlayerQuit(mcPlayerListener.java:51)
    at de.frozenbrain.MessageChanger.mcPlugin.getMessage(mcPlugin.java:94)
    at java.lang.String.replace(String.java:2219)
    java.lang.NullPointerException
    > 14:23:31 [SEVERE] Could not pass event PLAYER_QUIT to MessageChanger
    > 14:23:31 [INFO] [StealthLogin] Tara logged out secretly!
    and another question....
    can u add a custom message instead of "Outdated Server/Client" ?

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

    ariley92

    Yes, this would be lovely, so that inexperienced players who don't understand what's going on can be told more than just "Outdated Server!"
     
  8. Offline

    FrozenBrain

    Nope, still impossible, sorry.

    I'll upload a new version in a few moments that has support for that plugin (or should have).
     
  9. Offline

    paste120

    "Outdated Server"
    Is that because its a client side message, not sent from the server?
     
  10. Offline

    FrozenBrain

    It is sent by the server, but there's no way to change those messages without modifying the server AFAIK.
     
  11. Offline

    Taranis01

    at first instead of stoping i got the error 2x each time. Some hours later the error is gone... weird but great...thank you!
     
  12. Offline

    RTRD

    @FrozenBrain Is it possible to change the "Outdated server..." msg? :D
     
  13. Offline

    paste120

    Its hard coded into CraftBukkit in the class NetLoginHandler in the net.minecraft.server package line 68.

    After modifying that class myself:
    [​IMG]
     
  14. Offline

    FrozenBrain

    I'm always asking myself why people don't just read the few posts in this thread -.-

    Exactly. And we cannot override it as far as I know.
     
  15. Offline

    RTRD

    Haha, sorry! :p
     
  16. Offline

    paste120

    Not without compiling craftbukkit from source or just patching that class like I did. But neither is ideal, maybe in future updates they will make it customizable.
     
  17. Offline

    RTRD

    @paste120 What program did you use to edit the class?

    EDIT: Never mind, I used Java Class Editor.
     
  18. Offline

    imaxorz

    Can you point me to the editor you used?

    Or even better share the steps you took?

    Thank you.
     
  19. Offline

    FrozenBrain

    Updated for Minecraft 1.6.6 and fixed SERVER_STOP. It will now only kick people if the server is stopping, not when it's reloading the plugins. Have fun :)
     
  20. Offline

    meee

    Possible to add the "say" command? If someone write with the console to change "[Server] [Message]" to "[Meee] [Message]"?
     
  21. Offline

    daleisme

    Hi how do I use colors and how do I use this with my groups on "Permissions" Plugin?
     
  22. Offline

    Todrias

    The plugin is not working with Permissions 3 !
     
  23. Offline

    Taranis01

    @Todrias
    error-message?
    @FrozenBrain
    could you pls update to the newest recommend build and also to Permissions3?
     
  24. Offline

    FrozenBrain

    I've answered that already.

    Hey,
    I've just updated the plugin and rewrote the configuration part in the OP, it should be much easier to understand it now.

    Yup, the update's out. It's now working side-by-side with Permissions 3 and the configuration is now completely different.

    Please read the configuration part in the OP before updating from any version prior to 1.00.

    I haven't had much time to test the plugin and all it's possible use cases, so please report any bugs you may encounter.
     
    Taranis01 likes this.
  25. Offline

    Taranis01

    @FrozenBrain
    thank you :) im still on 1.6, but i will report all errors as soon i changed it.
    dont forget updating the Title of this Topic!
     
  26. Offline

    FrozenBrain

    Changed it already, just wanted to push to github first :)
     
  27. Offline

    Pythros

    Either I'm not seeing or it's not an option... is there a way to have multiple lines in the server kick/stop messages?
     
  28. Offline

    SneakyToe

    Haha, this plugin makes creativity 2% more possible in Minecraft, thanks a lot!
     
  29. Offline

    Jobsti

    Oh no it doesn't work with GroupManager (2.4) for me ;( ;(
     
  30. Offline

    jor956

    Change welcome message? Meaning the message when somebody logs in for the first time?
     
  31. Offline

    nacs

    MessageChanger is not working and is generating this error message in console on player joins (and also on quit):

    Is this because I am using Permissions 2.x?
     

Share This Page