Closed HorusApl closed 3 years ago
# ---------------------------------------------------------------------------------
# Timed messages broadcaster. Uses the same syntax as files in rules/ folder but
# operators are slightly different. For documentation and a quick tutorial, see:
# https://github.com/kangarko/ChatControl-Red/wiki/messages
#
# They are read like a newspaper and each player only sees one message,
# that is the first one we can send to him. We select 1 message randomly from
# "messages:" list.
# ---------------------------------------------------------------------------------
# You can run limited time offers and even make clickable links by referencing
# to a format from /formats in your message.
#group special
#expires 31 Dec 2021, 15:00
#then sound ENTITY_ARROW_HIT_PLAYER, 1.0, 0.1
#delay 6 seconds
#message:
#- special-offer
# This group will simply send messages everywhere.
group standard
delay 300 second
message:
- timed-buy
- timed-level
- &fAll resource worlds reset &x&f&0&3&0&3&0&lbi-weekly&f!
- timed-discord
- timed-mcmmo
- timed-vote
- &fSubmit any bugs/suggestions to the Discord!
- timed-help
- timed-resource
- timed-mobs
- timed-ref
- timed-profile
- &fHowus.
- timed-menu
- &fMake concrete easier! Throw the powder in a cauldron with water!
- timed-welcome
- timed-exp1
- timed-exp2
- timed-map
# This group will send messages only to the given worlds.
#group hardcore
#require sender world hardcore|hardcore_nether|hardcore_end
#message:
#- Grief is not permitted what-so-ever and every griefer will be banned.
#- Can you survive the night on {world} world?
# This group will only send messages to the creative world.
#group creative
#require sender world creative
#message:
#- Welcome on Creative world. Enjoy your gamemode :)
#- This is an example of multi-line.
# Use it if the new '\ and n' character
# is not working on your server.
#- This is another message, this time only on one line!
You should be able to do this with the toggle command. To make sure this works you will need to check in the settings.yml file, you have timed
listed in Toggle.Apply_On
.
The command for this can be edited if wanted under Toggle.Command_Aliases
. By default, the command should be /toggle
and /tg
The permission players will need I believe are as follows:
chatcontrol.command.toggle.timed
chatcontrol.command.toggle.on
chatcontrol.command.toggle.off
And lastly, the full command players will need to type is /toggle timed {group}
So for you, it will be: /toggle timed standard
Assuming this issue is sorted now, I'll close this but feel free to comment below if more help is needed
chc reload
[04:24:51 INFO]: [i] Reloading plugin's data, please wait..
[04:24:51 INFO]: ______________________________________________________________
[04:24:51 INFO]:
[04:24:51 INFO]: Reloading plugin ChatControlRed v10.7.9
[04:24:51 INFO]:
[04:24:51 INFO]: [PlaceholderAPI] Successfully registered expansion: chatcontrolred
[04:24:51 INFO]: !-----------------------------------------------------!
[04:24:51 INFO]: Error loading configuration in settings.yml!
[04:24:51 INFO]: Problematic section: Toggle
[04:24:51 INFO]: Problem: org.mineacademy.chatcontrol.lib.ReflectionUtil$MissingEnumException: The enum 'Toggle' does not contain 'timed' on MC v1_17_R1! Available values: mail, announcement, me, pm, chat (see below for more)
[04:24:51 INFO]: !-----------------------------------------------------!
[04:24:51 INFO]: ChatControlRed 10.7.9 encountered a MissingEnumException! Please check your error.log and report this issue with the information in that file.
[04:24:51 INFO]: ChatControlRed 10.7.9 encountered a MissingEnumException! Please check your error.log and report this issue with the information in that file.
[04:24:51 INFO]: org.mineacademy.chatcontrol.lib.ReflectionUtil$MissingEnumException: The enum 'Toggle' does not contain 'timed' on MC v1_17_R1! Available values: mail, announcement, me, pm, chat
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.ReflectionUtil.lookupEnum(ReflectionUtil.java:740)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.ReflectionUtil.lookupEnum(ReflectionUtil.java:614)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.SerializeUtil.deserialize(SerializeUtil.java:443)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlConfig.getList(YamlConfig.java:1123)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlConfig.getList(YamlConfig.java:1100)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlConfig.getSet(YamlConfig.java:1081)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig.getSet(YamlStaticConfig.java:419)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.settings.Settings.access$16000(Settings.java:49)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.settings.Settings$Toggle.init(Settings.java:681)
[04:24:51 INFO]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[04:24:51 INFO]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:78)
[04:24:51 INFO]: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[04:24:51 INFO]: at java.base/java.lang.reflect.Method.invoke(Method.java:567)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig.invokeMethodsIn(YamlStaticConfig.java:297)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig.invokeAll(YamlStaticConfig.java:271)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig.loadViaReflection(YamlStaticConfig.java:250)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig.access$000(YamlStaticConfig.java:47)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig$1.onLoadFinish(YamlStaticConfig.java:84)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlConfig.loadConfiguration(YamlConfig.java:344)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig.createFileAndLoad(YamlStaticConfig.java:335)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.SimpleSettings.load(SimpleSettings.java:41)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.settings.YamlStaticConfig.load(YamlStaticConfig.java:116)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.plugin.SimplePlugin.reload(SimplePlugin.java:668)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.command.ReloadCommand.onCommand(ReloadCommand.java:67)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.command.SimpleCommand.execute(SimpleCommand.java:396)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.command.SimpleCommandGroup$MainCommand.onCommand(SimpleCommandGroup.java:399)
[04:24:51 INFO]: at ChatControl-Red-10.7.9.jar//org.mineacademy.chatcontrol.lib.command.SimpleCommand.execute(SimpleCommand.java:396)
[04:24:51 INFO]: at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:159)
[04:24:51 INFO]: at java.base/java.lang.Thread.run(Thread.java:831)
[04:24:51 INFO]: !-----------------------------------------------------!
[04:24:51 INFO]: Failed to load static settings class org.mineacademy.chatcontrol.settings.Settings
[04:24:51 INFO]: !-----------------------------------------------------!
[04:24:51 INFO]:
[04:24:51 INFO]: Tutorial:
[04:24:51 INFO]: https://github.com/kangarko/ChatControl-Red/wiki
[04:24:51 INFO]:
[04:24:51 INFO]: Get help:
[04:24:51 INFO]: https://github.com/kangarko/ChatControl-Red/issues
[04:24:51 INFO]:
[04:24:51 INFO]: ______________________________________________________________
Tried what you suggested, and received this in response. Any ideas?
Your issue is caused by this part, under the toggle area:
# -------------------------------------------------------------------------------------------------
# Toggle seeing parts of the plugin - disable private messages, timed broadcasts, join messages etc
# -------------------------------------------------------------------------------------------------
Toggle:
# Where should we enable this feature?
# Available: chat, mail, announcement, me, pm
#
# Leave empty to completely prevent players from disabling all of these features.
Apply_On:
- 'announcement'
- 'timed'
# The commands that invoke the toggle command.
# EDIT AS YOU WISH BUT DO NOT REMOVE THE FIRST ALIAS
Command_Aliases:
- 'toggleall'
- 'broadcastoff'
As you can see above Apply_On
, the available options are: chat, mail, announcement, me, pm
but you specified timed
.
Remove timed
from the Apply_On
part and it'll solve your issue.
Did you see the conversation parts above? I know that's what was causing the issue and have removed it. I was told to put it there as an answer to my original question
My apologies, ignore everything I suggested except this :P
The permission players will need I believe are as follows:
chatcontrol.command.toggle.timed
chatcontrol.command.toggle.on
chatcontrol.command.toggle.off
And lastly, the full command players will need to type is
/toggle timed {group}
So for you, it will be:/toggle timed standard
I assumed you needed to add timed
for /toggle, to work for timed messages but turns out that should work without any config edits, as long as you have the perms listed above.
Trying to figure out a way to allow players to not receive/see the messages in my auto-broadcast in timed.rs, I am using a format .yml file for each of them if that matters. I saw the page on the wiki about the "require permission..." but not quite sure how to implement and where to put it. Will have my timed.rs file below if someone could point out what to do.
Minecraft Version: 1.17.1 MySQL: false BungeeCord: false