Jump to content
  • 0

Character Regen


ganjaradio

Question

3 answers to this question

Recommended Posts

  • 0

Hello where cna i change the caracters' regen for example if they walk to have more regen

calcHpRegen(L2Character cha)   its inside--> Formulas.java

 

find if (cha instanceof L2PcInstance)

 

this is the original  code:

// Calculate Movement bonus
if (player.isSitting())
hpRegenMultiplier *= 1.5;      // Sitting
else if (!player.isMoving())
hpRegenMultiplier *= 1.1; // Staying
else if (player.isRunning())
hpRegenMultiplier *= 0.7; // Running

and you can do something like this:

 

// Calculate Movement bonus
if (player.isSitting())
hpRegenMultiplier *= 1.5;      // Sitting
else if (!player.isMoving())
hpRegenMultiplier *= 1.1; // Staying
else 
if (player.isRunning())
hpRegenMultiplier *= 0.7; // Running
else
hpRegenMultiplier *= 0.9; // Walking

this is for hp regen.

 

for mp regen just search for calcMpRegen and cp  calcCpRegen

Edited by AbSoLuTePoWeR
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.


×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock