mirror of
https://gitlab.com/2009scape/2009scape.git
synced 2026-08-23 19:35:10 -06:00
fix retribution correctly
This commit is contained in:
parent
5b4d699e36
commit
3a5a71f6af
1 changed files with 4 additions and 1 deletions
|
|
@ -108,6 +108,9 @@ public final class Prayer {
|
|||
playAudio(player, Sounds.FIREBREATH_159);
|
||||
player.graphics(Graphics.create(437));
|
||||
int maximum = (int) (player.getSkills().getStaticLevel(Skills.PRAYER) * 0.25) - 1;
|
||||
if (killer != player && killer.getLocation().withinDistance(player.getLocation(), 1)) {
|
||||
killer.getImpactHandler().manualHit(player, 1 + RandomFunction.randomize(maximum), HitsplatType.NORMAL);
|
||||
}
|
||||
if (player.getProperties().isMultiZone()) {
|
||||
List<? extends Entity> targets;
|
||||
if (killer instanceof NPC) {
|
||||
|
|
@ -116,7 +119,7 @@ public final class Prayer {
|
|||
targets = RegionManager.getLocalPlayers(player.getLocation(), 1);
|
||||
}
|
||||
for (Entity entity : targets) {
|
||||
if (entity == player) {
|
||||
if (entity == player || entity == killer) {
|
||||
continue;
|
||||
}
|
||||
if (entity.isAttackable(player, CombatStyle.MAGIC, false)) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue