Exemplo n.º 1
0
 @Override
 public void onAction(int mouseX, int mouseY, int mouseButton) {
   if (super.intersectsWith(mouseX, mouseY)) {
     if (stat.canBeUnlocked(player, level + 1) && level < stat.maxLevel()) {
       GuiBase.playSound(Reference.MOD_ID + ":" + "gui.biotic_stat_unlock", 1, 1);
       MatterOverdrive.packetPipeline.sendToServer(
           new PacketUnlockBioticStat(stat.getUnlocalizedName(), ++level));
     }
   }
   super.onAction(mouseX, mouseY, mouseButton);
 }
Exemplo n.º 2
0
 public ElementBioStat(
     MOGuiBase gui,
     int posX,
     int posY,
     IBionicStat stat,
     int level,
     AndroidPlayer player,
     ForgeDirection direction) {
   super(gui, gui, posX, posY, stat.getUnlocalizedName(), 0, 0, 0, 0, 22, 22, "");
   texture = ElementSlot.getTexture("holo");
   texW = 22;
   texH = 22;
   this.stat = stat;
   this.player = player;
   this.level = level;
   this.direction = direction;
   cylinder = new Cylinder();
 }