diff options
| author | William Hergès <william@herges.fr> | 2025-09-20 15:39:51 +0200 |
|---|---|---|
| committer | William Hergès <william@herges.fr> | 2025-09-20 15:39:51 +0200 |
| commit | a0e93b4e031857e7379e2ab2d7bdae24561f4e5e (patch) | |
| tree | abc2a7b2d509552b20bd177520cbe4d8e1663670 /exp/functions.go | |
| parent | 8d6fa726069bd5364ada1521b400bb5eb7865d87 (diff) | |
feat(stats): better style for the graph
Diffstat (limited to 'exp/functions.go')
| -rw-r--r-- | exp/functions.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/exp/functions.go b/exp/functions.go index 363aed8..681c135 100644 --- a/exp/functions.go +++ b/exp/functions.go @@ -11,6 +11,8 @@ import ( "github.com/anhgelus/gokord" ) +const DebugFactor = 30 + func MessageXP(length uint, diversity uint) uint { return uint(math.Floor( 0.025*math.Pow(float64(length), 1.25)*math.Sqrt(float64(diversity)) + 1, @@ -67,7 +69,7 @@ func LevelXP(level uint) uint { func TimeStampNDaysBefore(n uint) string { var unix time.Time if gokord.Debug { - unix = time.Unix(time.Now().Unix()-int64(n), 0) // reduce time for debug + unix = time.Unix(time.Now().Unix()-int64(DebugFactor*n), 0) // reduce time for debug } else { unix = time.Unix(time.Now().Unix()-int64(n*24*60*60), 0) } |
