Changed the painting to art else it conflicts with disguisetype in disguisehelp
This commit is contained in:
		| @@ -90,8 +90,8 @@ public class DisguiseHelpCommand extends BaseDisguiseCommand { | ||||
|         } catch (Exception ex) { | ||||
|         } | ||||
|         try { | ||||
|             enumHelp.add(new EnumHelp("Painting", "Paintings", ChatColor.RED + "/disguisehelp Painting " + ChatColor.GREEN | ||||
|                     + "- View all the paintings you can use on a painting disguise", (Enum[]) Class.forName("org.bukkit.Art") | ||||
|             enumHelp.add(new EnumHelp("Art", "Arts", ChatColor.RED + "/disguisehelp Art " + ChatColor.GREEN | ||||
|                     + "- View all the painting arts you can use on a painting disguise", (Enum[]) Class.forName("org.bukkit.Art") | ||||
|                     .getEnumConstants())); | ||||
|         } catch (Exception ex) { | ||||
|         } | ||||
|   | ||||
| @@ -69,7 +69,7 @@ public class MiscDisguise extends Disguise { | ||||
|             ((FallingBlockWatcher) getWatcher()).setBlock(new ItemStack(this.id, 1, (short) this.data)); | ||||
|             break; | ||||
|         case PAINTING: | ||||
|             ((PaintingWatcher) getWatcher()).setPaintingId(this.data); | ||||
|             ((PaintingWatcher) getWatcher()).setArtId(this.data); | ||||
|             break; | ||||
|         case SPLASH_POTION: | ||||
|             ((SplashPotionWatcher) getWatcher()).setPotionId(this.data); | ||||
| @@ -123,7 +123,7 @@ public class MiscDisguise extends Disguise { | ||||
|         case FALLING_BLOCK: | ||||
|             return ((FallingBlockWatcher) getWatcher()).getBlock().getDurability(); | ||||
|         case PAINTING: | ||||
|             return ((PaintingWatcher) getWatcher()).getPainting().getId(); | ||||
|             return ((PaintingWatcher) getWatcher()).getArt().getId(); | ||||
|         case SPLASH_POTION: | ||||
|             return ((SplashPotionWatcher) getWatcher()).getPotionId(); | ||||
|         default: | ||||
|   | ||||
| @@ -15,15 +15,15 @@ public class PaintingWatcher extends FlagWatcher { | ||||
|     @Override | ||||
|     public PaintingWatcher clone(Disguise disguise) { | ||||
|         PaintingWatcher watcher = (PaintingWatcher) super.clone(disguise); | ||||
|         watcher.setPainting(getPainting()); | ||||
|         watcher.setArt(getArt()); | ||||
|         return watcher; | ||||
|     } | ||||
|  | ||||
|     public Art getPainting() { | ||||
|     public Art getArt() { | ||||
|         return painting; | ||||
|     } | ||||
|  | ||||
|     public void setPainting(Art newPainting) { | ||||
|     public void setArt(Art newPainting) { | ||||
|         this.painting = newPainting; | ||||
|         if (getDisguise().getEntity() != null && getDisguise().getWatcher() == this) { | ||||
|             DisguiseUtilities.refreshTrackers(getDisguise().getEntity()); | ||||
| @@ -31,7 +31,7 @@ public class PaintingWatcher extends FlagWatcher { | ||||
|     } | ||||
|  | ||||
|     @Deprecated | ||||
|     public void setPaintingId(int paintingNo) { | ||||
|     public void setArtId(int paintingNo) { | ||||
|         painting = Art.values()[paintingNo % Art.values().length]; | ||||
|     } | ||||
|  | ||||
|   | ||||
| @@ -330,7 +330,7 @@ public abstract class BaseDisguiseCommand implements CommandExecutor { | ||||
|                             try { | ||||
|                                 value = param.getClass().getMethod("valueOf", String.class).invoke(valueString.toUpperCase()); | ||||
|                             } catch (Exception ex) { | ||||
|                                 throw parseToException("painting", valueString, methodName); | ||||
|                                 throw parseToException("painting art", valueString, methodName); | ||||
|                             } | ||||
|                             // Parse to ocelot type | ||||
|                         } else if (param.getSimpleName().equals("Type")) { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user