File tree 1 file changed +17
-11
lines changed
packages/frontend/src/boot
1 file changed +17
-11
lines changed Original file line number Diff line number Diff line change @@ -216,19 +216,25 @@ export async function mainBoot() {
216
216
claimAchievement ( 'collectAchievements30' ) ;
217
217
}
218
218
219
- window . setInterval ( ( ) => {
220
- if ( Math . floor ( Math . random ( ) * 20000 ) === 0 ) {
221
- claimAchievement ( 'justPlainLucky' ) ;
222
- }
223
- } , 1000 * 10 ) ;
219
+ if ( ! claimedAchievements . includes ( 'justPlainLucky' ) ) {
220
+ window . setInterval ( ( ) => {
221
+ if ( Math . floor ( Math . random ( ) * 20000 ) === 0 ) {
222
+ claimAchievement ( 'justPlainLucky' ) ;
223
+ }
224
+ } , 1000 * 10 ) ;
225
+ }
224
226
225
- window . setTimeout ( ( ) => {
226
- claimAchievement ( 'client30min' ) ;
227
- } , 1000 * 60 * 30 ) ;
227
+ if ( ! claimedAchievements . includes ( 'client30min' ) ) {
228
+ window . setTimeout ( ( ) => {
229
+ claimAchievement ( 'client30min' ) ;
230
+ } , 1000 * 60 * 30 ) ;
231
+ }
228
232
229
- window . setTimeout ( ( ) => {
230
- claimAchievement ( 'client60min' ) ;
231
- } , 1000 * 60 * 60 ) ;
233
+ if ( ! claimedAchievements . includes ( 'client60min' ) ) {
234
+ window . setTimeout ( ( ) => {
235
+ claimAchievement ( 'client60min' ) ;
236
+ } , 1000 * 60 * 60 ) ;
237
+ }
232
238
233
239
// 邪魔
234
240
//const lastUsed = miLocalStorage.getItem('lastUsed');
You can’t perform that action at this time.
0 commit comments