Skip to main content

Production Actions

Verification boundary

This page documents the committed source. Treat revision-sensitive RuneLite UI, packet, or in-game outcomes as pending live-client verification unless the page records direct evidence.

Caution

We recorded a live-client gap for Make-X state serialization and the ONE quantity action: dispatch reported success without consuming an item or closing the interface. Treat production reads and quantity selection as pending replay until the documented Ruby-cutting scenario passes.

ProductionActions interacts with the Make-X production interface (widget group 270) and the legacy Smithing interface (widget group 312).

You can read interface state from ProductionActions for action guards. Workflow callers should use the production state described in Production Workflow.

Action Methods

  • chooseOption(int index) - clicks the item button at the given column index
  • chooseOption(String itemName) - clicks the first item whose name contains the given string (case-insensitive, tags stripped)
  • chooseOption(Predicate<String>) - clicks the first item matching the predicate; returns PRODUCTION_OPTION_NOT_FOUND on no match
  • selectQuantity(ProductionQuantity) - clicks the corresponding quantity button; returns PRODUCTION_NOT_OPEN if the interface is closed
  • selectMakeXQuantity(int qty) - two-step: clicks the X button then calls queueResumeCount(qty) to submit the custom amount
  • enterAmount(int amount) - queueResumeCount(amount) directly; use this when the input box is already open

Example:

if (ProductionActions.isOpen()) {
ProductionActions.chooseOption("Iron bar");
ProductionActions.selectQuantity(ProductionQuantity.ALL);
}

For a custom quantity:

ProductionActions.chooseOption("Bronze dart");
ProductionActions.selectMakeXQuantity(500);

ProductionQuantity Enum

ConstantAmountChild index in group 270
ONE10
FIVE51
TEN102
ALLInteger.MAX_VALUE3
X-1 (custom)4

Behavior notes:

  • All write methods are paced - they return PACED while the cooldown is active.
  • Any action method returns PRODUCTION_NOT_OPEN when neither production interface is visible.
  • The methods scan Smithing product buttons in stable child-ID order from group 312 child 9 through 35; quantity buttons use group 312 children 3, 4, 5, 7, and 6 for 1, 5, 10, All, and X.
  • selectMakeXQuantity bundles the button click and the count resume into a single tick call; the interface must accept the count packet in the same server tick.

Tanning Interface (TanningActions)

TanningActions covers the tanner interface (widget group 324, mapped from rev240 InterfaceID.Tanner). All writes are paced and return InteractionResult. A closed interface returns TANNING_NOT_OPEN; a hide lookup that matches zero or several slots returns TANNING_SLOT_NOT_FOUND.

  • isOpen() - whether the tanning interface is visible
  • tan(TanningSlot, TanningQuantity) - clicks the requested slot (SLOT_A..SLOT_H) with the requested quantity
  • tan(String hideName, TanningQuantity) - resolves the slot from the hide label text (case-insensitive, tags stripped, e.g. "Green dragon leather")
  • enterAmount(int amount) - submits the custom amount after choosing the X quantity
  • close() - clicks the interface close button

Example:

if (TanningActions.isOpen()) {
InteractionResult result = TanningActions.tan("Green dragon leather",
TanningActions.TanningQuantity.ALL);
if (result.getStatus() == InteractionStatus.PACED) {
return; // retry from the next tick
}
}

Because a tanning click only queues the menu action, verify the inventory actually gained leather (for example with Inventory.search()) before repeating a tan. Live-client verification is pending for the slot/quantity dispatch.