summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2013-10-27 00:16:45 +0200
committerHaru <haru@dotalux.com>2013-10-27 00:19:19 +0200
commit5dc1c33df515eac4eca7a7d8525ed67f4bda4af3 (patch)
tree1bdc4bb428a534d4d9fc19cb6b2caf8414b7120b
parenteba840c6e33658c00c89157e11dd3eba8fc977e2 (diff)
downloadhercules-5dc1c33df515eac4eca7a7d8525ed67f4bda4af3.tar.gz
hercules-5dc1c33df515eac4eca7a7d8525ed67f4bda4af3.tar.bz2
hercules-5dc1c33df515eac4eca7a7d8525ed67f4bda4af3.tar.xz
hercules-5dc1c33df515eac4eca7a7d8525ed67f4bda4af3.zip
Follow-up to 44c33fda3614d588e6bf6cee1cf884e98f1531f0
Corrected some 64 bit literal constants not declared as such, and causing compiler warnings and possible issues on some systems. Special thanks to Yommy. Signed-off-by: Haru <haru@dotalux.com>
-rw-r--r--src/map/status.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/map/status.c b/src/map/status.c
index fc032686e..70cc3bccf 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -7810,8 +7810,8 @@ int status_change_start(struct block_list* bl,enum sc_type type,int rate,int val
//Store time at which you started running.
int64 currenttick = timer->gettick();
// Note: this int64 value is stored in two separate int32 variables (FIXME)
- val3 = (int)(currenttick&0x00000000ffffffff);
- val4 = (int)((currenttick&0xffffffff00000000)>>32);
+ val3 = (int)(currenttick&0x00000000ffffffffLL);
+ val4 = (int)((currenttick&0xffffffff00000000LL)>>32);
}
tick = -1;
break;
@@ -8199,8 +8199,8 @@ int status_change_start(struct block_list* bl,enum sc_type type,int rate,int val
//Store time at which you started running.
int64 currenttick = timer->gettick();
// Note: this int64 value is stored in two separate int32 variables (FIXME)
- val3 = (int)(currenttick&0x00000000ffffffff);
- val4 = (int)((currenttick&0xffffffff00000000)>>32);
+ val3 = (int)(currenttick&0x00000000ffffffffLL);
+ val4 = (int)((currenttick&0xffffffff00000000LL)>>32);
}
tick = -1;
break;
@@ -9328,8 +9328,8 @@ int status_change_end_(struct block_list* bl, enum sc_type type, int tid, const
struct unit_data *ud = unit->bl2ud(bl);
bool begin_spurt = true;
// Note: this int64 value is stored in two separate int32 variables (FIXME)
- int64 starttick = (int64)sce->val3&0x00000000ffffffff;
- starttick |= ((int64)sce->val4<<32)&0xffffffff00000000;
+ int64 starttick = (int64)sce->val3&0x00000000ffffffffLL;
+ starttick |= ((int64)sce->val4<<32)&0xffffffff00000000LL;
if (ud) {
if(!ud->state.running)