This repository has been archived on 2024-12-29. You can view files and clone it, but cannot push or open issues or pull requests.
Files
nukkit-alphaapi/src/com/alphaae/mcpe/servers/utils/ToastUtils.java
2019-05-13 16:36:50 +08:00

20 lines
512 B
Java

package com.alphaae.mcpe.servers.utils;
import cn.nukkit.Player;
import cn.nukkit.utils.TextFormat;
public class ToastUtils {
public static final int INFO_TYPE_ERROR = 0;
public static final int INFO_TYPE_INFO = 1;
public static final int INFO_TYPE_WARNING = 2;
private static String[] infoTypeArr = new String[]{"&c", "&b", "&e"};
public static void Show(Player player, int infoType, String info) {
player.sendPopup(TextFormat.colorize(infoTypeArr[infoType] + info));
}
}