The check cumulative functions (checkDailyCumulative, checkWeeklyCumulative, etc.) in
|
fun checkDailyCumulative(player: Player) |
are only called when a player is online due to this check
|
val online = player.player ?: return |
Since the cumulative checks only see if the player has exactly the correct amount of votes, players do not receive cumulative rewards if they were offline for the last vote. This could be fixed in one of two ways:
- Keep track of the cumulative rewards a player did receive and change the cumulative check to check for greater than or equal to the required amount of votes.
- Add cumulative rewards to a player's claimable, redeeming them when the player next joins (as shown in this commit ParallelMC@084d78f. This exact solution isn't clean, but it may end up being less data to track).
The check cumulative functions (
checkDailyCumulative,checkWeeklyCumulative, etc.) inVoteParty/src/main/kotlin/me/clip/voteparty/handler/VotesHandler.kt
Line 100 in 01a0d4e
VoteParty/src/main/kotlin/me/clip/voteparty/listener/VotesListener.kt
Line 53 in 01a0d4e
Since the cumulative checks only see if the player has exactly the correct amount of votes, players do not receive cumulative rewards if they were offline for the last vote. This could be fixed in one of two ways: