Class TransportRequest
java.lang.Object
privbot.hooks.TransportRequest
Request for using a movement-catalog transport/NPC entry followed by an exact widget path.
Path steps are either visible option text (matched like dialogue), a packed widget id from the
Widget Inspector (
group << 16 | child), or an inspector path with nested indices when packed ids
collide (e.g. 820.49[44] — see Widgets.getByInspectorPath(java.lang.String)).-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classOne step along the post-interaction widget path: label text, packed widget id, or inspector path with optional[index]nesting. -
Constructor Summary
ConstructorsConstructorDescriptionTransportRequest(String movementEntryName, List<String> widgetPath) A movement-catalog entry followed by option texts, with default timeouts (30 s to reach the entry, 7.5 s per widget step) and the legacy workflow fallback allowed.TransportRequest(String movementEntryName, List<String> widgetPath, long navigationTimeoutMs, long widgetTimeoutMs, boolean allowWorkflowFallback) -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic TransportRequestforObject(net.runelite.api.coords.WorldPoint targetPoint, int targetRadius, String objectName, String objectAction, Object... widgetPath) Direct object interaction attargetPointplus widget path steps.static TransportRequestforObjectWithTimeouts(net.runelite.api.coords.WorldPoint targetPoint, int targetRadius, String objectName, String objectAction, long navigationTimeoutMs, long widgetTimeoutMs, Object... widgetPath) LikeforObject(WorldPoint, int, String, String, Object...)with explicit navigation / widget interaction timeouts (e.g.longnpcName()static TransportRequestMovement catalog entry name plus widget path steps.net.runelite.api.coords.WorldPointintlong
-
Constructor Details
-
TransportRequest
A movement-catalog entry followed by option texts, with default timeouts (30 s to reach the entry, 7.5 s per widget step) and the legacy workflow fallback allowed.- Parameters:
movementEntryName- the catalog entry's namewidgetPath- option texts to click after interacting, in order (may be empty)
-
TransportRequest
public TransportRequest(String movementEntryName, List<String> widgetPath, long navigationTimeoutMs, long widgetTimeoutMs, boolean allowWorkflowFallback) - Parameters:
movementEntryName- the catalog entry's namewidgetPath- option texts to click after interacting, in order (may be empty)navigationTimeoutMs- how long to walk toward the entrywidgetTimeoutMs- how long each widget step may waitallowWorkflowFallback- whether a saved legacy workflow may stand in
-
-
Method Details
-
of
-
forObject
public static TransportRequest forObject(net.runelite.api.coords.WorldPoint targetPoint, int targetRadius, String objectName, String objectAction, Object... widgetPath) -
forObjectWithTimeouts
public static TransportRequest forObjectWithTimeouts(net.runelite.api.coords.WorldPoint targetPoint, int targetRadius, String objectName, String objectAction, long navigationTimeoutMs, long widgetTimeoutMs, Object... widgetPath) LikeforObject(WorldPoint, int, String, String, Object...)with explicit navigation / widget interaction timeouts (e.g. longer widget phase when the server is slow to open interfaces). -
widgetSteps
- Returns:
- the widget steps, in order
-
movementEntryName
- Returns:
- the movement-catalog entry's name, or null for a direct object/NPC request
-
objectName
- Returns:
- the object to interact with directly, or null
-
objectAction
- Returns:
- the action on
objectName(), or null
-
npcName
- Returns:
- the NPC to interact with directly, or null
-
npcAction
-
targetPoint
public net.runelite.api.coords.WorldPoint targetPoint()- Returns:
- where the object or NPC is, or null
-
targetRadius
public int targetRadius()- Returns:
- tiles around
targetPoint()to search
-
widgetTimeoutMs
public long widgetTimeoutMs()- Returns:
- how long each widget step may wait for its target
-
allowWorkflowFallback
public boolean allowWorkflowFallback()- Returns:
- whether a saved legacy workflow may stand in when the direct interaction fails
-