Banners now work in 1.7-1.13 ( Tested )

This commit is contained in:
ProSavage 2018-08-11 01:14:18 -05:00
parent de3f0c4c87
commit 70e069dc05
3 changed files with 11 additions and 3 deletions

View File

@ -297,7 +297,7 @@
<dependency> <dependency>
<groupId>com.drtshock</groupId> <groupId>com.drtshock</groupId>
<artifactId>PlayerVaultsX</artifactId> <artifactId>PlayerVaultsX</artifactId>
<version>4.0.6-SNAPSHOT</version> <version>4.0.6</version>
<scope>provided</scope> <scope>provided</scope>
</dependency> </dependency>
<dependency> <dependency>

View File

@ -52,7 +52,15 @@ public class CmdBanner extends FCommand {
} else { } else {
warBanner = P.p.createItem(Material.LEGACY_BANNER, 1, (short) 1, P.p.getConfig().getString("fbanners.Item.Name"), P.p.getConfig().getStringList("fbanners.Item.Lore")); Material banner;
if (!P.p.mc113) {
banner = Material.valueOf("BANNER");
} else {
banner = Material.valueOf("LEGACY_BANNER");
}
warBanner = P.p.createItem(banner, 1, (short) 1, P.p.getConfig().getString("fbanners.Item.Name"), P.p.getConfig().getStringList("fbanners.Item.Lore"));
} }
fme.msg(TL.COMMAND_BANNER_SUCCESS); fme.msg(TL.COMMAND_BANNER_SUCCESS);
warBanner.setAmount(1); warBanner.setAmount(1);

View File

@ -20,7 +20,7 @@ public class CmdSetBanner extends FCommand {
} }
public void perform() { public void perform() {
if (me.getItemInHand().getType() != Material.LEGACY_BANNER) { if (!me.getItemInHand().getType().toString().contains("BANNER")) {
fme.msg(TL.COMMAND_SETBANNER_NOTBANNER); fme.msg(TL.COMMAND_SETBANNER_NOTBANNER);
return; return;
} }