no godir change if no movement (just in case)

This commit is contained in:
Zeno Rogue 2019-05-11 23:55:57 +02:00
parent eec99b96df
commit 7669633fbf
1 changed files with 1 additions and 1 deletions

View File

@ -1655,7 +1655,7 @@ void movePlayer(monster *m, int delta) {
godir[cpid] = 0;
if(WDIM == 2 && GDIM == 3) {
if(WDIM == 2 && GDIM == 3 && (mdx || mdy)) {
double mdd = hypot(mdx, mdy);
godir[cpid] = -atan2(mdx, -mdy);
mgo += mdd;