Jump to content

werlex

Members
  • Posts

    35
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

About werlex

Profile Information

  • Gender
    Not Telling

werlex's Achievements

Newbie

Newbie (1/16)

0

Reputation

  1. i saw this L2PetInstance pet = (L2PetInstance) activeChar.getPet(); and i thought that this code with pet :D
  2. this is not for pet? when activechar get lvl 20 with pet exp will decrease by 2 for activechar?
  3. Horus, Firstly i said that iam just starting work with java, Secondly your code with attacker is wrong because i get error for attacker (with intrepid we was talking about this), Third what you help for me with this code? Intrepid said that need to put else, i put it and everything okay then ... what you said more than "1 is neutral, we can dont write it". If you need that credits ill write ... its not very hard for me ...
  4. that code was not finished :D with my java knoweledge i need your help :D
  5. horus sorry for my english ... when character reach level 76 then exp rate will be 5 for him... lakis Dont spam ...
  6. Hello, here is my first share. This code is good when you want to do something like when mob lvl is 76 or bigger, exp rate can be smaller. Iam using L2jarchid. open com.l2jarchid.gamesserver.model.actor.L2npc.java Find: public int getExpReward() { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } REPLACE IT TO: public int getExpReward() { if (getLevel() > 75) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 1); } else { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } } rateXp * 1 is exp rate you can change it to 20 or etc (number only change)... This code is when mob lvl is 76 or bigger exp rate will be 1... if you want to do intervals like from 52 to 65 - 20 exp , 65-76 - 10 exp 76 or bigger - 5 exp rate ... write this code public int getExpReward() { if (getLevel() > 52 && getLevel() < 66) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 20); } if (getLevel() > 66 && getLevel() < 75) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 10); } if (getLevel() > 75) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 5); } else { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } } I think this code will be usefull Credits to Intrepid,Horus and me ... P.S. if someone will share code for character exp(when character reach 76lvl then exp for him will count as 1) will be great :) public int getExpReward() { L2Attackable attacker; if (getLevel() > 75) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 5); } else { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } } if some1 can test write feedback (i dont test it, maybe it work, for characters lvl)
  7. if character leve <76 , he get's only exp from <76 mobs ... this return; i think dont help me yea? ... maybe is possible to make something like when mob level lover 3 levels than character level then character will dont get exp ?
  8. no sorry for my mistake everything is ok ... just when mob is 75 level xp rate is 200 ... when mob is 76 exp rate is 1 exp ... everything ok just now need to think how to do when lvl mob is lover than 76 people dont get exp ....
  9. if (getLevel() > 76) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 1); } else { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } } with this code when mob is 76 lvl he 1 exp rate .... thank you now just need to do when level 76 or lover dont get exp from lover mobs ... its possible?
  10. if (getLevel() > 76) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 1); } else { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } } something like this ? or with horus offer?
  11. put here your buffer ... because we dont know what kind of buffs you are using ... clan hall or normal...
  12. yes ... dont need that 1?
  13. hi i have edited model.actor.l2npc.java file if (getLevel() > 76) { double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * 1.0); } double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } i want to do something like after 76lvl exp rate become 1 exp ... maybe some1 can help me with this thing ? Real code Real code [code] } double rateXp = getStat().calcStat(Stats.MAX_HP, 1, this, null); return (int) (getTemplate().rewardExp * rateXp * Config.RATE_XP); } [/code]
  14. thank you very much ... i will try this ... :)
  15. dont need new soe put into sql databasE? Thank you very much for this tutorial ....
×
×
  • Create New...