@@ -494,42 +494,42 @@ async def inventory_farming(self, ctx: Ctx, user: discord.User | discord.Member
494494 async def vault_deposit (self , ctx : Ctx , emerald_blocks : str ):
495495 """Deposits the given amount of emerald blocks into the vault"""
496496
497- db_user = await self .db .fetch_user (ctx .author .id )
497+ # db_user = await self.db.fetch_user(ctx.author.id)
498498
499- if db_user .emeralds < 9 :
500- await ctx .reply_embed (ctx .l .econ .dep .poor_loser )
501- return
499+ # if db_user.emeralds < 9:
500+ # await ctx.reply_embed(ctx.l.econ.dep.poor_loser)
501+ # return
502502
503+ amount : int | Literal ["Max" ]
503504 if emerald_blocks .lower () in ("all" , "max" ):
504- amount = db_user .vault_max - db_user .vault_balance
505-
506- if amount * 9 > db_user .emeralds :
507- amount = math .floor (db_user .emeralds / 9 )
505+ amount = "Max"
508506 else :
509507 try :
510508 amount = int (emerald_blocks )
511509 except ValueError :
512510 await ctx .reply_embed (ctx .l .econ .use_a_number_stupid )
513511 return
514512
515- if amount * 9 > db_user .emeralds :
516- await ctx .reply_embed (ctx .l .econ .dep .stupid_3 )
517- return
513+ # if amount * 9 > db_user.emeralds:
514+ # await ctx.reply_embed(ctx.l.econ.dep.stupid_3)
515+ # return
518516
519- if amount < 1 :
520- if emerald_blocks .lower () in ("all" , "max" ):
521- await ctx .reply_embed (ctx .l .econ .dep .stupid_2 )
522- else :
523- await ctx .reply_embed (ctx .l .econ .dep .stupid_1 )
517+ # if amount < 1:
518+ # if emerald_blocks.lower() in ("all", "max"):
519+ # await ctx.reply_embed(ctx.l.econ.dep.stupid_2)
520+ # else:
521+ # await ctx.reply_embed(ctx.l.econ.dep.stupid_1)
524522
525- return
523+ # return
526524
527- if amount > db_user .vault_max - db_user .vault_balance :
528- await ctx .reply_embed (ctx .l .econ .dep .stupid_2 )
529- return
525+ # if amount > db_user.vault_max - db_user.vault_balance:
526+ # await ctx.reply_embed(ctx.l.econ.dep.stupid_2)
527+ # return
528+
529+ # await self.db.balance_sub(ctx.author.id, amount * 9)
530+ # await self.db.set_vault(ctx.author.id, db_user.vault_balance + amount, db_user.vault_max)
530531
531- await self .db .balance_sub (ctx .author .id , amount * 9 )
532- await self .db .set_vault (ctx .author .id , db_user .vault_balance + amount , db_user .vault_max )
532+ await self .karen .commands .vault .deposit (ctx .k .user .id , blocks = amount )
533533
534534 await ctx .reply_embed (
535535 ctx .l .econ .dep .deposited .format (
0 commit comments