Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestion: Add "receiver" operators to rules #2893

Open
bobhenl opened this issue Dec 12, 2024 · 6 comments
Open

Suggestion: Add "receiver" operators to rules #2893

bobhenl opened this issue Dec 12, 2024 · 6 comments

Comments

@bobhenl
Copy link

bobhenl commented Dec 12, 2024

Are you using MySQL?

No

Are you using a proxy?

No

Question

Hello, how can I send message like channel announcement SO there isn't player prefix & name upfront of it? Like no chat format.

I tried /channel send
but it adds the formatting, I wanna send it like without the name as announcement

OR is it possible to create new "message" that is triggered only via cmd where I can set the viewer perm? Or it's not possible to create the custom ones triggerable only via cmd?

Context: I'd like to catch some rule & send the "TIP message" for the specific group of players, I can forcejoin them channel or use view permission, but I'm not sure how exactly it could be done due to described issues

@bobhenl
Copy link
Author

bobhenl commented Dec 12, 2024

Also one more question, is there possibility to add "wait" or "delay" between command execution in rules? The current delay is like "cooldown", but in case I want to wait 1s before executing the cmd?

@kangarko
Copy link
Owner

I recommend you create a new rule and a new format. Then link the format to the warn message in the rule:

Yes, you can use the "delay" operator to set a delay

match yourMatch
player delay 10 seconds Please wait {delay} before running this command again.
then warn sampleFormat
then deny

See rules/commands.rs for examples.

In the above example, if I type yourMatch then I will see the formats/sampleFormat.yml formatted message.

@bobhenl
Copy link
Author

bobhenl commented Dec 20, 2024

But wait, this will show to the sender, ineed to show it to the receiver like:
require receiver variable {floodgate_isbedrock} true
@kangarko

and I guess I cannot add it to the format neither to the rule like this or? Like if I do warn it will show just to the specific player, not everyone & only to these with the variable

@kangarko
Copy link
Owner

What is your intended use of this rule? Kludne napis aj po cesky.

@bobhenl
Copy link
Author

bobhenl commented Dec 21, 2024

OK, takže:
Snažím se udělat to, že když hráči použijí [item], tak to catchnu v global.rs, a poté pošlu zprávu těm čtenářům, kteří jsou na Bedrocku, že mohou použít speciální příkaz k zobrazení

Jakože udělal jsem to přes timed zprávy, že jsem tam dal 0 delay a dělám to teď takto
console chc message run timed bedrock-inv

a tam mám tu podmínku, že receiver musí být Bedrock hráč

ale to mi trochu rozbíjí asi použití timed zpráv v budoucnu? Nelze to nějak jinak? @kangarko

@kangarko
Copy link
Owner

Rozumiem, vdaka. Momentalne ale nemame podporu pre "receiver" vo formats, ta je k dispozicii len pre messages/. To je nieco co mozem skusit pridat v buducnost ked budem mat viac casu.

@kangarko kangarko reopened this Dec 24, 2024
@kangarko kangarko changed the title 1.21.1: How to send channel message like announcement? 1.21.1: Add "receiver" operators to rule Dec 24, 2024
@kangarko kangarko changed the title 1.21.1: Add "receiver" operators to rule 1.21.1: Add "receiver" operators to rules Dec 24, 2024
@kangarko kangarko changed the title 1.21.1: Add "receiver" operators to rules Add "receiver" operators to rules Dec 24, 2024
@kangarko kangarko changed the title Add "receiver" operators to rules Suggestion: Add "receiver" operators to rules Dec 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants