All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.dailystruggle.rtp.common.commands.BaseRTPCmd Maven / Gradle / Ivy

The newest version!
package io.github.dailystruggle.rtp.common.commands;

import io.github.dailystruggle.commandsapi.common.localCommands.TreeCommand;
import io.github.dailystruggle.rtp.common.RTP;
import io.github.dailystruggle.rtp.common.configuration.ConfigParser;
import io.github.dailystruggle.rtp.common.configuration.enums.MessagesKeys;

import java.util.UUID;

public interface BaseRTPCmd extends TreeCommand {
    @Override
    default void msgBadParameter(UUID callerId, String parameterName, String parameterValue) {
        ConfigParser lang = (ConfigParser) RTP.configs.getParser(MessagesKeys.class);

        String msg = String.valueOf(lang.getConfigValue(MessagesKeys.badArg, ""));
        msg = msg.replace("[arg]", parameterName + ":" + parameterValue);
        RTP.serverAccessor.sendMessage(callerId, msg);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy