Welcome to MaxCheaters.com

Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads

Code Set up one attribute per armor piece on L2JSunrise


Recommended Posts

Hy there i decided to share something even is not a big deal , but i already shared on sunrise . 
Put the following line on requestexenchantitemattribute.class

       Elementals oldElement = item.getElemental(elementToAdd);
      int elementValue = oldElement == null ? 0 : oldElement.getValue();
      int limit = getLimit(item, stoneId);
      int powerToAdd = getPowerToAdd(stoneId, elementValue, item);
      
//    if ((item.isWeapon() && (oldElement != null) && (oldElement.getElement() != elementToAdd) && (oldElement.getElement() != -2)) || (item.isArmor() && (item.getElemental(elementToAdd) == null) && (item.getElementals() != null) && (item.getElementals().length >= 3)))
      if ((item.isWeapon() && (oldElement != null) && (oldElement.getElement() != elementToAdd) && (oldElement.getElement() != -2)) || (item.isArmor() && (item.getElemental(elementToAdd) == null) && (item.getElementals() != null) && (item.getElementals().length >= 1)))
      
  • Thanks 1
  • Upvote 1

Share this post


Link to post
Share on other sites
7 hours ago, Terminal said:

Hy there i decided to share something even is not a big deal , but i already shared on sunrise . 
Put the following line on requestexenchantitemattribute.class


       Elementals oldElement = item.getElemental(elementToAdd);
      int elementValue = oldElement == null ? 0 : oldElement.getValue();
      int limit = getLimit(item, stoneId);
      int powerToAdd = getPowerToAdd(stoneId, elementValue, item);
      
//    if ((item.isWeapon() && (oldElement != null) && (oldElement.getElement() != elementToAdd) && (oldElement.getElement() != -2)) || (item.isArmor() && (item.getElemental(elementToAdd) == null) && (item.getElementals() != null) && (item.getElementals().length >= 3)))
      if ((item.isWeapon() && (oldElement != null) && (oldElement.getElement() != elementToAdd) && (oldElement.getElement() != -2)) || (item.isArmor() && (item.getElemental(elementToAdd) == null) && (item.getElementals() != null) && (item.getElementals().length >= 1)))
      

Lol  yesterday I think about change to 1 attitude of armors ... thanks for share ..!

 

Did u test it ?

Share this post


Link to post
Share on other sites

usually is not allowed sharing small codes, also its better sharing a diff or pastebin and say a few things what it is and how it works, thank you for sharing it tho and happy holidays :)

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.