mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-27 01:05:38 +00:00
The Lie.
This commit is contained in:
parent
716ba57739
commit
539f28549a
@ -18,6 +18,10 @@ public class Command_cake extends TFM_Command
|
|||||||
@Override
|
@Override
|
||||||
public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole)
|
public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole)
|
||||||
{
|
{
|
||||||
|
ItemStack C = new ItemStack(Material.CAKE);
|
||||||
|
ItemMeta CM = C.getItemMeta();
|
||||||
|
CM.setDisplayName((new StringBuilder()).append(ChatColor.WHITE).append("The ").append(ChatColor.BLACK).append("Lie").toString());
|
||||||
|
C.setItemMeta(CM);
|
||||||
StringBuilder output = new StringBuilder();
|
StringBuilder output = new StringBuilder();
|
||||||
Random randomGenerator = new Random();
|
Random randomGenerator = new Random();
|
||||||
|
|
||||||
@ -30,7 +34,7 @@ public class Command_cake extends TFM_Command
|
|||||||
|
|
||||||
for (Player player : server.getOnlinePlayers())
|
for (Player player : server.getOnlinePlayers())
|
||||||
{
|
{
|
||||||
ItemStack heldItem = new ItemStack(Material.CAKE, 1);
|
ItemStack heldItem = new ItemStack(C);
|
||||||
player.getInventory().setItem(player.getInventory().firstEmpty(), heldItem);
|
player.getInventory().setItem(player.getInventory().firstEmpty(), heldItem);
|
||||||
player.awardAchievement(Achievement.MINE_WOOD);
|
player.awardAchievement(Achievement.MINE_WOOD);
|
||||||
player.awardAchievement(Achievement.BUILD_WORKBENCH);
|
player.awardAchievement(Achievement.BUILD_WORKBENCH);
|
||||||
|
Loading…
Reference in New Issue
Block a user