diff options
| author | Anhgelus Morhtuuzh <anhgelus.morhtuuzh@proton.me> | 2024-04-15 19:06:33 +0200 |
|---|---|---|
| committer | Anhgelus Morhtuuzh <anhgelus.morhtuuzh@proton.me> | 2024-04-15 19:06:33 +0200 |
| commit | 0a6ecf6af7dc8df0a2255ddb7c022cfad6452493 (patch) | |
| tree | f19a7c876a947b79d100780dbb730ee3fea36c59 /xp/level.go | |
| parent | 9de1f3f90b2d94215f14458a11a951cb143a8dc2 (diff) | |
feat(xp): implements xp reducer
Diffstat (limited to 'xp/level.go')
| -rw-r--r-- | xp/level.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xp/level.go b/xp/level.go index 14d0e95..b179cdb 100644 --- a/xp/level.go +++ b/xp/level.go @@ -43,7 +43,7 @@ func onNewLevel(s *discordgo.Session, m *discordgo.Member, level uint) { } } -func onLastEventUpdate(c *Copaing) { +func LastEventUpdate(c *Copaing) { h := c.HourSinceLastEvent() l := Lose(h, c.XP) xp := c.XPAlreadyRemoved() @@ -57,7 +57,7 @@ func onLastEventUpdate(c *Copaing) { c.SetLastEvent() } -func onXPUpdate(c *Copaing) { +func XPUpdate(c *Copaing) { h := c.HourSinceLastEvent() l := Lose(h, c.XP) xp := c.XPAlreadyRemoved() |
