brenoepics / morningstar

An open-source Arcturus Community Fork.
GNU General Public License v3.0
3 stars 2 forks source link

Update Voucher.java - [merged] #1501

Closed brenoepics closed 1 year ago

brenoepics commented 2 years ago

In GitLab by @oshawott on Jan 26, 2022, 08:44

Merges vouchers-fix -> dev

Voucher history is taking the history of all vouchers into account instead of just that individual voucher.

hasUserExhausted(): Limit is the amount of times any single Habbo can redeem that voucher. Any vouchers that have a limit of X will not work if the Habbo has ever redeemed >= X amount of vouchers, no matter the voucher code, redeemed or not..

isExhausted(); Amount is the amount of times it's redeemed before it's counted as exhausted. Because the total history size of all vouchers is taken into account and not just the history of the specific voucher, it will show any voucher as falsely exhausted when the total of all vouchers redeemed exceeds the redeem amount of any specific voucher.

brenoepics commented 2 years ago

In GitLab by @oshawott on Apr 9, 2022, 06:29

added 94 commits

Compare with previous version

brenoepics commented 2 years ago

In GitLab by @Harmonic on Apr 9, 2022, 22:18

mentioned in commit dc73b8529b4506eea3eb4580b62fd7a9f53fcd9f