Jump to content

ShinichiYao

Members
  • Posts

    18
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

1 Follower

About ShinichiYao

Profile Information

  • Gender
    Male
  • Country
    China

Recent Profile Visitors

1,121 profile views

ShinichiYao's Achievements

Newbie

Newbie (1/16)

5

Reputation

  1. public double calc(L2Character caster, L2Character target, Skill skill, double initVal) { double value = initVal; double mul = 1; for (AbstractFunction func : _functions) { if ((func instanceof FuncMul) && ((func.getStat() == Stats.CRITICAL_RATE) || (func.getStat() == Stats.MCRITICAL_RATE)) && (func.getValue() > 1)) { mul += func.getValue() - 1; } else { if (mul > 1) { value *= mul; mul = 1; } value = func.calc(caster, target, skill, value); } } if (mul > 1) { value *= mul; } return value; }
  2. Nice share! Anyway to disable user action while autofarm is on such as mouse click move action use etc?
  3. Can meet Beleth by my self
  4. Well my work is based on Elfocrash's code and the environment is original L2J Server H5 but its quite modified in both core and dp which adapted a lot of additional change such as skill rework and dressme system. And also as you see, my server is totally Chinese localization, its very difficult to separate the roboto part out of the entire server.
  5. Yeah the old engine could cause up to 20% of CPU usage after adapting Larger quantity and complex AI. I wonder how you make this optimized and great work again!
  6. Made another pvp video
  7. Your engine is good, most of my time is spend at itemId collect and union with dressme system.
  8. Yes it in FakePlayerAI.java And you can get enemies like this List<L2Character> targets = _fakePlayer.getKnownList().getKnownCharactersInRadius(radius).stream().filter(x -> (checkTargetThreat(x) && GeoData.getInstance().canSeeTarget(_fakePlayer, x))).collect(Collectors.toList());
  9. You just need to make a check function so that the fake player may know who is the enemy, this is my code based on L2J Server protected boolean checkTargetThreat(L2Character target) { if (target == null) { return false; } if (target.isDead() || target.isInvisible() || (_fakePlayer.getLeader() == target)) { return false; } if (target.isPlayable() && (target.isInsideZone(ZoneId.PEACE) || target.isInsideZone(ZoneId.NO_SUMMON_FRIEND))) { return false; } if (target.isPlayer()) { L2PcInstance player = (L2PcInstance) target; if (player.isFake() && _fakePlayer.isSameSide((FakePlayer) player)) { return false; } if ((player.getKarma() > 0) || (player.getPvpFlag() > 0)) { return true; } if ((player.isInsideZone(ZoneId.PVP) && (player.getActiveWeaponInstance() != null)) || player.isInsideZone(ZoneId.SIEGE)) { return true; } } else if (target.isSummon()) { L2Summon summon = (L2Summon) target; if ((summon.getKarma() > 0) || (summon.getPvpFlag() > 0)) { return true; } if (summon.isInsideZone(ZoneId.PVP) || summon.isInsideZone(ZoneId.SIEGE)) { return true; } } else if (target.isAttackable()) { if (!target.isTargetable()) { return false; } if (target.isRaid() && ((target.getLevel() + 8) < _fakePlayer.getLevel())) { return false; } if (target.isNpc() && ((((L2Npc) target).getId() == 2502) || (((L2Npc) target).getId() == 2503))) { return false; } if (target.isMonster()) { return true; } if (target.getTarget() == _fakePlayer) { return true; } if ((target.getTarget() != null) && target.getTarget().isPlayer()) { if (((L2PcInstance) target.getTarget()).isInPartyWith(_fakePlayer)) { return true; } } } return false; }
  10. It's based on Elfocrash's work, and my core and DP are quite modified not easy to separate for other L2J version.
  11. Sweet engine I made this Raid video https://youtu.be/YWg1XfYx1zQ
×
×
  • Create New...