Вопрос Выполнение команды после регистрации

skelay

Пользователь
Сообщения
49
Решения
2
Плагин
Authme
Ядро сервера
  1. Purpur
Версия сервера
  1. 1.16+
Память сервера ОЗУ
8Gb
Подскажите как сделать выполнение команды после регистрации игрока в authme, я смотрел гайды но все гайды старые и файл command изменился
 
Решение
В самом же файле commands.yml есть очень даже подробная инструкция...
YAML:
# This configuration file allows you to execute commands on various events.
# Supported placeholders in commands:
#   %p is replaced with the player name.
#   %nick is replaced with the player's nick name
#   %ip is replaced with the player's IP address
#   %country is replaced with the player's country
#
# For example, if you want to send a welcome message to a player who just registered:
# onRegister:
#   welcome:
#     command: 'msg %p Welcome to the server!'
#     executor: CONSOLE
#
# This will make the console execute the msg command to the player.
# Each command under an event has a name you can choose freely (e.g. 'welcome' as above),
# after which a...
В самом же файле commands.yml есть очень даже подробная инструкция...
YAML:
# This configuration file allows you to execute commands on various events.
# Supported placeholders in commands:
#   %p is replaced with the player name.
#   %nick is replaced with the player's nick name
#   %ip is replaced with the player's IP address
#   %country is replaced with the player's country
#
# For example, if you want to send a welcome message to a player who just registered:
# onRegister:
#   welcome:
#     command: 'msg %p Welcome to the server!'
#     executor: CONSOLE
#
# This will make the console execute the msg command to the player.
# Each command under an event has a name you can choose freely (e.g. 'welcome' as above),
# after which a mandatory 'command' field defines the command to run,
# and 'executor' defines who will run the command (either PLAYER or CONSOLE). Longer example:
# onLogin:
#   welcome:
#     command: 'msg %p Welcome back!'
#     executor: PLAYER
#   broadcast:
#     command: 'broadcast %p has joined, welcome back!'
#     executor: CONSOLE
#
# You can also add delay to command. It will run after the specified ticks. Example:
# onLogin:
#   rules:
#     command: 'rules'
#     executor: PLAYER
#     delay: 200
#
# Supported command events: onLogin, onSessionLogin, onFirstLogin, onJoin, onLogout, onRegister, onUnregister
#
# For onLogin and onFirstLogin, you can use 'ifNumberOfAccountsLessThan' and 'ifNumberOfAccountsAtLeast'
# to specify limits to how many accounts a player can have (matched by IP) for a command to be run:
# onLogin:
#   warnOnManyAccounts:
#     command: 'say Uh oh! %p has many alt accounts!'
#     executor: CONSOLE
#     ifNumberOfAccountsAtLeast: 5
# Commands to run for players logging in whose 'last login date' was empty
 
@ANameSpace,я знаю, но есть одно но, когда я убираю любой # сервер не включается больше
Можешь показать ошибку и свой файл?
Авто объединение сообщений:

@ANameSpace,я знаю, но есть одно но, когда я убираю любой # сервер не включается больше
У тебя скорее всего есть какая-то ошибка в твоём файле.
Посмотри мой как пример.
 

Вложения

  • commands.yml
    2 KB · Просмотры: 9
Последнее редактирование:
ANameSpace,
@ANameSpace,хз что с ним стало но я решил полностью удалить плагин и скачать заново, помогло даже папку его не пришлось удалять
Немного странно, что скачивание нового файла той же версии без изменения папки плагина помогло исправить ошибку, но главное, что работает.
@ANameSpace,я знаю, но
offtop Ставь после упоминание пробел, иначе форум считает его просто текстом
 
Последнее редактирование:
Назад
Сверху Снизу