Jump to content
  • 0

Help With Charactercreate.java


Question

Posted (edited)

What should I change to make my char start with full hp? currently when I create new char his HP is set to 80/314, see link for image http://joxi.ru/J2bN6NPsdbok26

 

I believe I should change smth in .setCurrentHp(template.getBaseHpMax()); but im not sure what exactly to do.

int objectId = IdFactory.getInstance().getNextId();
            L2PcInstance newChar = PlayerEnteringManager.getInstance().create(objectId, template, getClient().getAccountName(), _name, _hairStyle, _hairColor, _face, _sex != 0);
            newChar.getStatus().setCurrentHp(template.getBaseHpMax());
            newChar.getStatus().setCurrentCp(template.getBaseCpMax());
            newChar.getStatus().setCurrentMp(template.getBaseMpMax());
Edited by dBayway

5 answers to this question

Recommended Posts

  • 0
Posted

 

newChar.setCurrentHp(newChar.getMaxHp());
newChar.setCurrentMp(newChar.getMaxMp());
newChar.setCurrentMp(newChar.getMaxCp());

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


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