/[projects]/miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/chests/AdvancedChest.java
ViewVC logotype

Diff of /miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/chests/AdvancedChest.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1852 by torben, Tue Oct 2 09:16:21 2012 UTC revision 1853 by torben, Tue Oct 2 16:40:56 2012 UTC
# Line 140  public class AdvancedChest  implements L Line 140  public class AdvancedChest  implements L
140                  }                  }
141                                    
142                  if (cmd.equals("remove")) {                  if (cmd.equals("remove")) {
143                            if (chest == null) {
144                                    player.sendMessage("This chest is not protected");
145                                    return true;
146                            }
147                          if (! chest.getOwner().equals( player.getName() ) ) {                          if (! chest.getOwner().equals( player.getName() ) ) {
148                                  player.sendMessage("You can not remove lock from a chest you don't own");                                  player.sendMessage("You can not remove lock from a chest you don't own");
149                                  return true;                                  return true;
150                          }                          }
151                          if (chest != null) {  
152                                  player.sendMessage("[LockedChest] Removing protection from chest");                          player.sendMessage("[LockedChest] Removing protection from chest");
153                                  removeChest(loc);                                                        removeChest(loc);                              
154                          } else {  
                                 player.sendMessage("This chest is not protected");        
                         }  
155                          return true;                          return true;
156                  }                  }
157                                    

Legend:
Removed from v.1852  
changed lines
  Added in v.1853

  ViewVC Help
Powered by ViewVC 1.1.20