Advertisement
johnlol

TCG Banker2

Aug 2nd, 2023
867
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VeriLog 0.92 KB | Gaming | 0 0
  1. prontera,128,213,5  script  TCG Banker  407,{
  2. switch( select( "^0000FFDeposit^000000 "+.coin_name$,"^008000Withdraw^000000 "+.coin_name$ ) ){
  3.     case 1:
  4.         mes "How many "+.coin_name$+" to ^0000FFDeposit^000000 ??";
  5.         mes "^FF0000Max^000000 : "+countitem( .coin_id )+" "+.coin_name$;
  6.         input .@amount,0,countitem( .coin_id );
  7.         if( .@amount ){
  8.             delitem .coin_id,.@amount;
  9.             #coin_bank += .@amount;
  10.         }
  11.         else{
  12.             mes "^0000FFDeposit^000000 ^FF0000cancelled^000000.";
  13.         }
  14.         break;
  15.     case 2:
  16.         mes "How many "+.coin_name$+" to ^008000Withdraw^000000 ??";
  17.         mes "^FF0000Max^000000 : "+#coin_bank+" "+.coin_name$;
  18.         input .@amount,0,#coin_bank;
  19.         if( .@amount ){
  20.             getitem .coin_id,.@amount;
  21.             #coin_bank -= .@amount;
  22.         }
  23.         else{
  24.             mes "^008000Withdraw^000000 ^FF0000cancelled^000000.";
  25.         }
  26.         break;
  27. }
  28. close;
  29.  
  30. OnInit:
  31.     .coin_id = 7227;
  32.     .coin_name$ = getitemname( .coin_id );
  33.     waitingroom "TCG Banker",0;
  34.     end;
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement