From 9a4648ebbf3edae508daebb88fb52f2928135eb8 Mon Sep 17 00:00:00 2001 From: Cydh Ramdh Date: Wed, 20 Nov 2019 07:47:30 +0700 Subject: [PATCH] Fixed #4452 (#4457) * Correction for checking SLS's days --- src/map/date.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/map/date.cpp b/src/map/date.cpp index f9fa71d3c3..c1ab3915c1 100644 --- a/src/map/date.cpp +++ b/src/map/date.cpp @@ -135,7 +135,7 @@ int date_get( enum e_date_type type ) */ bool is_day_of_sun(void) { - return date_get_dayofyear()%2 == 0; + return (date_get_dayofyear()+1)%2 == 0; } /* @@ -143,7 +143,7 @@ bool is_day_of_sun(void) */ bool is_day_of_moon(void) { - return date_get_dayofyear()%2 == 1; + return (date_get_dayofyear()+1)%2 == 1; } /* @@ -151,5 +151,5 @@ bool is_day_of_moon(void) */ bool is_day_of_star(void) { - return date_get_dayofyear()%5 == 0; + return (date_get_dayofyear()+1)%5 == 0; }