Example #1
0
 @Override
 public void resizeBoundingBox(boolean flag) {
   EntitySize es = this.getClass().getAnnotation(EntitySize.class);
   if (es != null) {
     this.setSize(flag ? (es.width() / 2) : es.width(), flag ? (es.height() / 2) : es.height());
   }
 }
Example #2
0
 @Override
 public void resetEntitySize() {
   EntitySize es = this.getClass().getAnnotation(EntitySize.class);
   if (es != null) {
     this.setSize(es.width(), es.height());
   }
 }
Example #3
0
 protected void setSize() {
   EntitySize es = this.getClass().getAnnotation(EntitySize.class);
   if (es != null) {
     this.setSize(es.width(), es.height());
   }
 }