1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-08-23 06:45:04 +02:00
This commit is contained in:
Iaccidentally
2012-08-07 01:49:35 -04:00
7 changed files with 49 additions and 5 deletions

View File

@@ -18,7 +18,7 @@ public class Block {
public ItemStack convertToItem()
{
final ItemStack is = ItemStack.create(this.getType(), 1, this.getDurability());
return this.getType().convertToItem(is);
final ItemStack is = ItemStack.create(this.stack.getType(), 1, this.stack.getDurability());
return this.stack.getType().convertToItem(is);
}
}

View File

@@ -1,9 +1,9 @@
package net.ess3.bukkit;
import net.ess3.api.server.CommandSender;
import net.ess3.api.server.Permission;
import lombok.Delegate;
import lombok.Getter;
import net.ess3.api.server.CommandSender;
import net.ess3.api.server.Permission;
public class BukkitCommandSender implements CommandSender
@@ -29,6 +29,7 @@ public class BukkitCommandSender implements CommandSender
return commandSender.isOp();
}
@Override
public boolean hasPermission(Permission permission)
{
if (commandSender == null) {
@@ -37,4 +38,16 @@ public class BukkitCommandSender implements CommandSender
return commandSender.hasPermission(((BukkitPermission)permission).getBukkitPermission());
}
}
@Override
public void sendMessage(String message)
{
commandSender.sendMessage(message);
}
@Override
public void sendMessage(String[] string)
{
commandSender.sendMessage(string);
}
}

View File

@@ -18,6 +18,18 @@ public class BukkitMaterial extends Material
}
}
@Override
public int getId()
{
return this.material.getId();
}
@Override
public int getMaxStackSize()
{
return this.material.getMaxStackSize();
}
private interface Excludes {
short getMaxDurability();
}

View File

@@ -197,4 +197,10 @@ public class TestPlayer implements Player {
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public boolean isInSurvivalMode()
{
throw new UnsupportedOperationException("Not supported yet.");
}
}

View File

@@ -6,6 +6,7 @@ import java.util.logging.Logger;
import net.ess3.api.server.Location;
import net.ess3.api.server.Player;
import net.ess3.api.server.Plugin;
import net.ess3.api.server.Server;
public class TestPlugin implements Plugin {
@@ -93,4 +94,10 @@ public class TestPlugin implements Plugin {
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public Server getServer()
{
throw new UnsupportedOperationException("Not supported yet.");
}
}

View File

@@ -86,4 +86,10 @@ public class TestServer implements Server {
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public Player getPlayer(String name)
{
throw new UnsupportedOperationException("Not supported yet.");
}
}

View File

@@ -74,7 +74,7 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<bukkit.version>1.2.5-R4.1-SNAPSHOT</bukkit.version>
<bukkit.version>1.3.1-R0.1-SNAPSHOT</bukkit.version>
<build.number>Unknown</build.number>
<org-netbeans-modules-editor-indent.CodeStyle.project.expand-tabs>true</org-netbeans-modules-editor-indent.CodeStyle.project.expand-tabs>
<org-netbeans-modules-editor-indent.CodeStyle.project.indent-shift-width>2</org-netbeans-modules-editor-indent.CodeStyle.project.indent-shift-width>