SimpleUc
SimpleUc
A simple plugin adapted by LRLEW's UnknownCommand-Plugin, that lets you set a custom message, that will displayed when the command couldn't be found.
Features
Everyone knows the "UnknownCommand"-message (Default is "Unknown command. Type "help" for help."). This Plugin lets you edit the message, that is returned when a player types a unknown command.
- Single Uc-Message
- More than one randomly choosen Uc-Messages
- Prevent Uc-Messages (added in v1.2)
- Command Correction (finished in v1.2.1)
- Hide + Disable commands (added in v1.3)
Thanks to UltiByte for this video! :)
Configuration
The configuration is very simple! Look here if you need help with the config! For a example Configuration, look here.
Go on page Configuration for the description.
Commands and Permissions
| Command | Permission | Description |
|---|---|---|
| /uc | simpleuc.* | Info about SimpleUc |
| /uc-reload | simpleuc.reload | Reload SimpleUc's Config |
| simpleuc.cc.all | Command Correction for commands with no permission too | |
| simpleuc.hide.exempt | Bypass the hidden commands |
Upcoming Features
v2.0: (advanced config)
- Group messages
- Player messages
- Set Uc-messages with commands
- Custom Uc's for specific predefined commands
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Es ist besser wenn wir über PM weiterschreiben^^
-
View User Profile
-
Send Message
Posted Feb 22, 2013@Minecrell
Hi,
wenn ich nur SimpleUc, PermissionsEx und cShortCut im Plguin Verzeichnis habe geht es auch bei mir ohne Probleme. Also habe ich mal angefangen zu testen und neu zu starten. Zum Glück ist das noch ein TestServer. Ich habe 54 Plugins im Einsatz und habe diese nach und nach hinzugefügt. Wenn ich eins der unten aufgeführten aktiviere kommt die Meldung "Unbekannter Befehl". Hast du eines dieser Plugins im Einsatz? Wenn nein, dann versuch es doch bitte mal ob bei dir ein Fehler auftritt wenn du eins davon verwendest.
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Wirklich merkwürdig... Wie gesagt bei mir geht alles ohne Probleme... (auch mit deiner config.yml)
-
View User Profile
-
Send Message
Posted Feb 22, 2013@Minecrell
Aber klar doch:
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Hmm, aber eigentlich hat das nichts mit den zu versteckenden Befehlen zu tun... Kannst du mir mal deine cShortcut config.yml zeigen?(nur das /ucr) bei mir geht es nämlich ohne Meldung...
-
View User Profile
-
Send Message
Posted Feb 22, 2013@Minecrell
command-correction: enabled: true
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Was ist jetzt gegenüber der letzen config.yml anders?
-
View User Profile
-
Send Message
Posted Feb 22, 2013@Minecrell
Hi,
nein ich habe nur simpleuc.reload als Recht sonst nichts mit simpleuc Mit dieser config.yml kommt die Meldung "Unbekannter Befehl", so wie erwartet. Bei Verwendung von Shortcuts, Z.B. bei /ucr für /uc-reload, erscheint ebenfalls "Unbekannter Befehl" und die Meldung SimpleUc reloaded,was ja anzeigt, das der Schortcut abgearbeitet wurde.
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Und du selber hast nicht simpleuc.hide.exempt?
-
View User Profile
-
Send Message
Posted Feb 22, 2013@Minecrell
Meine config.yml
/ucr ist ein shortcut für /uc reload. Es erscheint die obige Meldung aus der config.yml /plugins oder /pl werden ausgeführt ohne Meldung! Die Plugins werden ausgegeben.
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Do you see both messages (from Bukkit and the unknown command message) or only the Bukkit ones?
EDIT: It works for me, maybe you tested it with permission simpleuc.hide.exempt?
-
View User Profile
-
Send Message
Posted Feb 22, 2013@Minecrell
Yes, I tried, but it didn't work, neither with enabled: true nor enabled: false.
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Do you tried to hide those commands?
http://dev.bukkit.org/server-mods/simpleuc/pages/configuration/#w-how-to-hide-commands
Speak that language that you want to speak :D
-
View User Profile
-
Send Message
Posted Feb 22, 2013@Minecrell
@Minecrell
Yes, it works fine.
I got an idea, about en section where i can enter an command, an then the user gets an error.
At the moment i do it with cshortcut, but its a bit more work then adding it here. What do you think about?
I'm speaking native german.
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Thanks! It works now.
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Does it work now with cShortcut?
-
View User Profile
-
Send Message
Posted Feb 22, 2013@jrdmetsfan
Hi,
try it with with 2 single quote and not 1 double qoute
-
View User Profile
-
Send Message
Posted Feb 22, 2013I want to enable the random messages but when I try, it only comes up as the normal Uc message. How can I fix this?
This is part of my config file:
prevent-messages: false
message: '&cUnknown Command.'
random-messages: true
messages:
- '&4You might want to use a real command next time.'
- '&2Yeah… we don't have that command.'
- '&cYou failed that command isn't here.'
- '&3Well someone derped...'
- '&4Try another command because this one doesn't exist.'
I also got this error:
11:46:29 [SEVERE] Cannot load plugins/SimpleUc/config.yml
org.bukkit.configuration.InvalidConfigurationException while parsing a block mapping
in "<string>", line 5, column 1:
prevent-messages: false
^
expected <block end>, but found Scalar
in "<string>", line 10, column 21:
- '&2Yeah… we don't have that command.'
^
at org.bukkit.configuration.file.YamlConfiguration.loadFromString(YamlConfiguration.java:55)
at org.bukkit.configuration.file.FileConfiguration.load(FileConfiguration.java:138)
at org.bukkit.configuration.file.FileConfiguration.load(FileConfiguration.java:105)
at org.bukkit.configuration.file.YamlConfiguration.loadConfiguration(YamlConfiguration.java:175)
at org.bukkit.plugin.java.JavaPlugin.reloadConfig(JavaPlugin.java:117)
at org.bukkit.plugin.java.JavaPlugin.getConfig(JavaPlugin.java:111)
at net.minecrell.bukkit.simpleuc.Config.cfg(Config.java:42)
at net.minecrell.bukkit.simpleuc.Config.getHiddenCmdsSection(Config.java:102)
at net.minecrell.bukkit.simpleuc.Config.hideCommands(Config.java:106)
at net.minecrell.bukkit.simpleuc.UcListener.onPlayerCommandPreprocess(UcListener.java:73)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:425)
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62)
at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:477)
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:462)
at net.minecraft.server.v1_4_R1.PlayerConnection.handleCommand(PlayerConnection.java:972)
at net.minecraft.server.v1_4_R1.PlayerConnection.chat(PlayerConnection.java:898)
at net.minecraft.server.v1_4_R1.PlayerConnection.a(PlayerConnection.java:853)
at net.minecraft.server.v1_4_R1.Packet3Chat.handle(Packet3Chat.java:44)
at net.minecraft.server.v1_4_R1.NetworkManager.b(NetworkManager.java:290)
at net.minecraft.server.v1_4_R1.PlayerConnection.d(PlayerConnection.java:113)
at net.minecraft.server.v1_4_R1.ServerConnection.b(SourceFile:39)
at net.minecraft.server.v1_4_R1.DedicatedServerConnection.b(SourceFile:30)
at net.minecraft.server.v1_4_R1.MinecraftServer.r(MinecraftServer.java:598)
at net.minecraft.server.v1_4_R1.DedicatedServer.r(DedicatedServer.java:224)
at net.minecraft.server.v1_4_R1.MinecraftServer.q(MinecraftServer.java:494)
at net.minecraft.server.v1_4_R1.MinecraftServer.run(MinecraftServer.java:427)
at net.minecraft.server.v1_4_R1.ThreadServerApplication.run(SourceFile:849)
Caused by: while parsing a block mapping
in "<string>", line 5, column 1:
prevent-messages: false
^
expected <block end>, but found Scalar
in "<string>", line 10, column 21:
- '&2Yeah… we don't have that command.'
^
at org.yaml.snakeyaml.parser.ParserImpl$ParseBlockMappingKey.produce(ParserImpl.java:575)
at org.yaml.snakeyaml.parser.ParserImpl.peekEvent(ParserImpl.java:161)
at org.yaml.snakeyaml.parser.ParserImpl.checkEvent(ParserImpl.java:146)
at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java:230)
at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160)
at org.yaml.snakeyaml.composer.Composer.composeDocument(Composer.java:123)
at org.yaml.snakeyaml.composer.Composer.getSingleNode(Composer.java:106)
at org.yaml.snakeyaml.constructor.BaseConstructor.getSingleData(BaseConstructor.java:121)
at org.yaml.snakeyaml.Yaml.loadFromReader(Yaml.java:480)
at org.yaml.snakeyaml.Yaml.load(Yaml.java:399)
at org.bukkit.configuration.file.YamlConfiguration.loadFromString(YamlConfiguration.java:53)
... 30 more
-
View User Profile
-
Send Message
Posted Feb 22, 2013@ThoLav
Kein Problem :P / No problem :P
-
View User Profile
-
Send Message
Posted Feb 22, 2013Ich war zu langsam!
Werde ich nachher probieren.
Danke!