Support for the latest build of L2J Server, get help here with installations, upgrades, problems.
Do not post bugs reports here, use viewforum.php?f=77 instead. There is no support for other server builds than the official provided by l2jserver.com
If you want to receive support we need this info to help you properly. » Find Revision
L2J Revision 6377:
L2JDP Revision 10159:
Hello,
I'm using one of the unstable revisions (just before all NPCs moved to xml!)
The question: I want to set internally the items to be as +6 even if they are +20 or even +100 so that skills don't get unbalanced. In what direction to go and can we do this by changing only one core file.
Like the file that is reading the enchant level of an item and set it? What file it is?
Thank you
Last edited by HappyLDE on Sat Mar 22, 2014 9:26 am, edited 1 time in total.
Thank you for making L2JServer happen!
"If you believe you will fail or succeed, in both ways you are right." - Henry Ford
Thank you! In L2ItemInstance i changed the getEnchantLevel() function. In the insertIntoDb, restoreFromDb and updateInDb functions i used _enchantLevel instead of getEnchantLevel().
So items from +1 to +25 are calculated into +1 to +8
Of course it wouldn't work as you wish because that is the value returned to send to the clients to display "enchant glow".
Go to L2ItemInstace#getEnchantLevel() and right click it and select "Open Call Hierarchy" and it will bring up a window with about 35 calls, ignore all that related to system messages and packets (like trade and user info) follow those that go into the part of code related to HP and attack calculations and you could call getNerfedEnchantLevel() method that is your method and have your own formula.
Powered by Eclipse 4.34 | Eclipse Temurin 21 | MariaDB 11.3.2 | L2J Server 2.6.3.0 - High Five
And now it works! Since getNerfedEnchantLevel() return +8 if item is +25 and +26 if item is +26 the difference in damage, patk, pdef, skill and hp is huge as if applies correctly. And visually it looks +25 even if power +8 now.
Thank you!
Thank you for making L2JServer happen!
"If you believe you will fail or succeed, in both ways you are right." - Henry Ford
And now it works! Since getNerfedEnchantLevel() return +8 if item is +25 and +26 if item is +26 the difference in damage, patk, pdef, skill and hp is huge as if applies correctly. And visually it looks +25 even if power +8 now.