igroglaz / srvmgr

https://rom2.ru
8 stars 5 forks source link

Possible float overflow when magic duration > 4096sec #1

Closed freevatar closed 4 years ago

freevatar commented 4 years ago

The bug is related to magic duration when corresponding skill is high enough.

When magic duration is supposed to be more than 4096sec, overflow occurs and counter starts from zero.

Here is an example:

  1. Case 1 Astral: 192 Magic shield duration: 3944sec

  2. Case 2 (Overflow) Astral: 194 Magic shield duration: 47.6sec

serg-bloim commented 4 years ago

Issue and fix explained: https://github.com/igroglaz/srvmgr/wiki/Spell-duration-overflow

igroglaz commented 4 years ago

https://github.com/igroglaz/srvmgr/commit/91bb5e244dac2836b5b96e39e37634396b8e8668