Jump to content
  • 0

Mana Regen


Komnis

Question

9 answers to this question

Recommended Posts

  • 0

It should be in character templates (since these things are attached to a player character class).

 

Movement/Wait mode modifiers are hardcoded, check formulas or related Func implementing classes if you need to change them as well.

Link to comment
Share on other sites

  • 0

Easy to say hard to do it as a beginner. Can you give me more information so i can do what i want?

 

As an alterbative, if make a passive skill which give more mp regen and put that skill in all classes will be the same?

Link to comment
Share on other sites

  • 0

Character templates used to be in SQL, but now they are in XML, although the paths differ in different serverpacks (datapack, look for char_templates or character or similar folders).

 

And no, it will not be exactly the same (unless you use a multiplier instead of a flat value):

MP_regen = max(orgMP_regen × menBonusF × levelBonus × skillMP_regenPer + skillMP_regenDiff, 1)
P.S. I am unsure if CHA affects regen as well.

 

In short:

If you want to multiply/divide the MP regen (e.g. make it double) -> the result will be the same.

If you want to add a flat value (e.g. +5 / recovery tick), it will not be the same (MEN, level bonuses as well as mul/div effects will have no effect on the value added by a skill).

 

Of course, L2J's generalized calculator allows you to simply use a smaller order value (this means you would effectively create a custom MP regen formula without changing code). I think it was 32 (0x20) for add/sub instead of 64 (0x40).

Edited by _dev_
Link to comment
Share on other sites

  • 0

Character templates used to be in SQL, but now they are in XML, although the paths differ in different serverpacks (datapack, look for char_templates or character or similar folders).

 

And no, it will not be exactly the same (unless you use a multiplier instead of a flat value):

MP_regen = max(orgMP_regen × menBonusF × levelBonus × skillMP_regenPer + skillMP_regenDiff, 1)
P.S. I am unsure if CHA affects regen as well.

 

In short:

If you want to multiply/divide the MP regen (e.g. make it double) -> the result will be the same.

If you want to add a flat value (e.g. +5 / recovery tick), it will not be the same (MEN, level bonuses as well as mul/div effects will have no effect on the value added by a skill).

 

Of course, L2J's generalized calculator allows you to simply use a smaller order value (this means you would effectively create a custom MP regen formula without changing code). I think it was 32 (0x20) for add/sub instead of 64 (0x40).

 

there's no column in character template for mp reg and there's no xml file for char stats.i checked them both. So i will try to add it on passive skill and i please the gods to work fine. Is there a guide for the orders(0x20,0x40 etc.) because there's no guide to fully explain how orders exactly work... :/

Link to comment
Share on other sites

  • 0

there's no column in character template for mp reg and there's no xml file for char stats.i checked them both. So i will try to add it on passive skill and i please the gods to work fine. Is there a guide for the orders(0x20,0x40 etc.) because there's no guide to fully explain how orders exactly work... :/

Well, I was primarily referring to this: https://github.com/L2J/L2J_DataPack/blob/master/dist/game/data/stats/chars/baseStats/AbyssWalker.xml

 

Here's a short guide for the orders. Assume you have certain values, already with operation attached:

 

+10 -20 *6 *2 *1.05 +63.2 *0.5 /3

 

You need to calculate a value. An easy way to do it is (parenthesis emphasize the natural operation order):

10 - (20 * 6 * 2 * 1.05) + (63.2 * 0.5 / 3)

 

Obviously, the "insertion order" calculation is not good for… mostly anything.

 

So now you have certain values with both operation and order attached, e.g.

 

+10[1] -20[15] *6[5] *2[5] *1.05[2] +63.2[15] *0.5[10] /3[2]

 

Now, you only have to sort the orders:

((((10) / 3 * 1.05) * 6 * 2) * 0.5) + 63.2 - 20

 

Which will end up providing a different value.

 

Obviously, you would want to avoid +- having the same order as */, because for the same order value, they can end up ordered in any way, and (x*2)+10 is different than (x+10)*2.

 

In order to allow intermediate values (for future updates), l2j has selected certain order values to be used in item/skill templates:

0x10 for base value <set>

0x20 for base value <add/sub>

0x30 for (base) value <mul/div> (due to multiplication semantics, we do not need to split it into two)

0x40 for modifying the precomputed value by <add/sub>

0x50 for one-sided <set> (overriding the completely computed value)

Link to comment
Share on other sites

  • 0

lol why so hard coding  while he can do it with the easy way LAWL?

He asked to change (note the difference between 'adjust'/'modify' and 'change'/'replace') the default value. So it is only natural that we tried to guide him to the default values.

 

Once again, a skill with <mul> will participate in MP regen formula differently than a skill with <add>, when compared to just changing the default value.

Link to comment
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.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   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.



  • Posts

    • New locations pool! Try it and make your effency greater with Asocks.com!
    • Greetings, Adventurers! 🎉 Announcement: L2 Noxis OBT Server Launch! 🎉 Adventurers of Aden, the moment you’ve been waiting for is here! We are thrilled to announce the official launch of the L2 Noxis Open Beta Test (OBT) Server! Gear up and get ready to embark on an epic journey in the world of Lineage 2 with a plethora of new and exciting features: 🔥 Features of L2 Noxis: Path of Rogue server: Modern Auto-Hunting System: Enjoy a seamless and modern auto-hunting experience, just like in the Essence chronicle. Free To Play Structure: Earn Einhasad's Golden Coins and Tarot cards through various in-game activities, making your adventure rewarding and enjoyable. Long-Term Project: Join us in a long-term commitment to provide a stable, exciting, and evolving gaming environment. Robust Anti-Cheat System: Play with confidence knowing that we have implemented a top-notch anti-cheat system to ensure a fair and balanced gaming experience. Newest Chronicle - Lineage 2: Path of Rogue: Experience the latest chronicle with new content, challenges, and adventures. New Classes: Unleash the power of the Death Knight and the mystical abilities of the Shinemaker. Discover new skills, abilities, and strategies with these exciting classes. Enhanced Rates: Enjoy 2x experience points and 2x adena drop rate, making your progression faster and more rewarding. Join us on this incredible journey and be among the first to experience the wonders of the L2 Noxis server. Gather your friends, form alliances, and conquer the lands of Aden!   📅 Launch Date: [July 10, 2024]   Stay tuned for more updates and get ready to explore, battle, and thrive in the world of L2 Noxis! For more information and instructions how to join the OBT, visit our official website: L2Noxis.com See you in Aden, warriors! 🌟     L2 Noxis Team  
  • Topics

×
×
  • Create New...