From 9fbe770db9fc520225cabdd38da3df57691846a8 Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Fri, 17 Jun 2022 10:56:31 +0200 Subject: [PATCH] ghosts prioritize attacking players over attacking allies --- monstermove.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/monstermove.cpp b/monstermove.cpp index 7ae8df9a..737c5a40 100644 --- a/monstermove.cpp +++ b/monstermove.cpp @@ -1528,7 +1528,7 @@ EX void moveghosts() { vector mdir; - for(int j=0; jtype; j++) + for(int p: {0, 1}) for(int j=0; jtype; j++) if(p == 1 || (c->move(j) && isPlayerOn(c->move(j)))) if(c->move(j) && canAttack(c, c->monst, c->move(j), c->move(j)->monst, AF_GETPLAYER | AF_ONLY_FBUG)) { // XLATC ghost/greater shark