Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.outlook.rcottone;
- import org.bukkit.Bukkit;
- import org.bukkit.ChatColor;
- import org.bukkit.command.CommandSender;
- import org.bukkit.entity.Player;
- public class SendTelegram {
- public static void Send(Player args2, String[] args, String string)
- {
- Player senda = Bukkit.getServer().getPlayer(string);
- if (args.length > 1 || !(args.length > 4))
- {
- args2 = Bukkit.getServer().getPlayer(args[0]);
- if (args2.isOnline())
- {
- args2.sendMessage(ChatColor.BLACK + "=========================");
- args2.sendMessage(ChatColor.RED + "" + ChatColor.BOLD + "Incoming Telegram!");
- args2.sendMessage(ChatColor.GREEN + "" + ChatColor.BOLD + "Sender: " + senda.getName());
- args2.sendMessage(ChatColor.BLUE + "" + ChatColor.BOLD + args[1] + args[2] + args[3] + args[4]);
- args2.sendMessage(ChatColor.BLACK + "=========================");
- senda.sendMessage(ChatColor.GREEN + "" + ChatColor.BOLD + "Telegram Sent.");
- }
- else
- {
- Main.saveForOfflinePlayer(args2, args);
- }
- }
- else
- {
- senda.sendMessage("A Telegram must be 4 words or less!");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement