Skip to content

Commit c0e7d16

Browse files
Update bank.simba
Just added something that deposits all items in the inventory. Did my best to format the info the same as you.
1 parent f7c6b4c commit c0e7d16

File tree

1 file changed

+32
-2
lines changed

1 file changed

+32
-2
lines changed

osrs/interfaces/mainscreen/bank.simba

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -707,8 +707,7 @@ begin
707707
Result := Self.ClearSearch() and
708708
Chat.AnswerQuery('Show items', '', Random(2000, 2500));
709709
end;
710-
711-
710+
712711
(*
713712
## Bank.HasIncinerator
714713
```pascal
@@ -1135,6 +1134,37 @@ begin
11351134
if Inventory.Items.Find(item, slot) then
11361135
Result := Self._InteractionHelper(ERSBankInteraction.DEPOSIT, slot, 1, useQuantityButton);
11371136
end;
1137+
(*
1138+
##Bank.DepositInventory
1139+
```pascal
1140+
function TRSbank.DepositInventory: Boolean;
1141+
```
1142+
Deposits All Items In Inventory into the bank. Doesn't close bank after depositing.
1143+
Example:
1144+
```pascal
1145+
Procedure Test;
1146+
1147+
begin
1148+
Map.Setup([ERSChunk.VARROCK]);
1149+
bank.DepositInventory;
1150+
end;
1151+
```
1152+
*)
1153+
1154+
function TRSBank.DepositInventory: Boolean;
1155+
begin
1156+
begin
1157+
If bank.open Then
1158+
Bank.DynamicButtons[ERSBankDynamicButtons.DEPOSIT_INVENTORY].Click(EMouseButton.LEFT)
1159+
Else Bank.open;
1160+
Result:=True;
1161+
end;
1162+
begin
1163+
If not Inventory.slots.CountEmpty then
1164+
Bank.DynamicButtons[ERSBankDynamicButtons.DEPOSIT_INVENTORY].Click(EMouseButton.LEFT);
1165+
Result:=True;
1166+
end;
1167+
end;
11381168

11391169

11401170
(*

0 commit comments

Comments
 (0)