Skip to main content

Check Region

Tests a rectangle of the screen against a rule — no template image required.

Purpose

Checks a rectangle without any captured image: is it bright enough, the right average colour, a specific pixel colour, or has it changed since the last check?

Use it to detect state that has no distinct icon — a health bar that emptied, a screen that faded in, a light that turned on, an area that is animating.

When to use it

  • Detecting a bar, gauge, or meter changing level.
  • Confirming a screen faded in or out.
  • Detecting any movement in an area, without knowing what it will look like.
  • Checking a status light or colour-coded indicator.

When not to use it

  • To find an icon or button — use Find Image.
  • To read a value — use Read Text.
  • On a busy, detailed area. Averaging a complex region washes out the signal.

Requirements

A connected device. No template asset needed — that is the point of this node.

How it runs

As with Find Image, a not-passed is not an error: the route is Failure but the status is success, so it never trips retry or the consecutive-failure guardrail.

Settings

SettingTypeRangeDefaultWhat it does
Regionrectanglepercentage of screenRequired. The area to measure
Rule typechoicesee belowRequired. What to measure
ExpectedobjectRequired. The target value to compare against
Tolerancenumber≥ 0How far the measurement may differ and still pass
Timeoutinteger100–120000 msflow defaultHow long to keep checking
Poll intervalinteger50–5000 msflow defaultHow often to re-capture

The four rules

RuleMeasuresTypical use
colorAverageThe region's average colourA colour-coded panel or indicator
brightnessThe region's average brightnessA bar that lights up, a screen fading
pixelColorOne specific pixel's colourA small status light
changedSinceLastFrameWhether the region differs from the previous pollAny motion or animation

changedSinceLastFrame is the interesting one

This rule compares each capture against the previous poll's capture. You do not need to know what the area will look like — only that it will be different.

That makes it the right tool for "wait until the animation stops" or "detect that something is moving", which no template can express.

Tolerance

A tolerance of 0 almost never passes against a real screen: compression, anti-aliasing and subtle gradients mean measurements are never exactly equal. Allow slack.

Start generous, then tighten until it stops passing when it shouldn't.

Ports

PortTaken whenRequired
SuccessThe rule passedYes
FailureThe rule did not pass before the timeout (status still success)No
CancelledThe run was stopped mid-checkNo — never followed
FatalCapture failed, the region is invalid, or the rule / expected value could not be parsedNo — never followed

Basic example

Detect that a health bar is still lit:

  • Region: a small patch of the bar
  • Rule: Brightness
  • Expected: 0.5
  • Tolerance: 0.15

Success while the bar is lit; Failure when it goes dark.

Realistic example — wait for an animation to finish

A fixed Wait guesses. This measures:

Here Failure is the good outcome: "the region stopped changing" means the animation finished. This inverted reading is common with changedSinceLastFrame, and it is why wiring both ports thoughtfully matters.

Advanced example — a gauge threshold

Detect that a resource bar has dropped below roughly a quarter full by measuring a patch a quarter of the way along it:

  • Region: a small patch at the 25% mark of the bar
  • Rule: Colour average
  • Expected: the bar's "empty" background colour
  • Tolerance: moderate

Success means the bar no longer reaches that point.

This works where no icon exists and no text is shown — exactly the gap this node fills.

Best practices

  • Keep the region small and on a stable, representative patch. Averaging a large area destroys the signal.
  • Always wire Failure. Not-passed leaves through it, and an unwired port ends the run.
  • Give tolerance real slack. Zero tolerance is a bug, not precision.
  • Use changedSinceLastFrame for settling, and remember that "not changed" arrives on Failure.
  • Prefer Find Image when an icon exists. Template matching is more specific and easier to reason about.
  • Test on both states. A rule that passes when it should is only half the check — confirm it fails when it should too.

Performance notes

  • Check Region is cheaper than both Find Image and OCR — it measures pixel statistics over a crop rather than matching or recognising.
  • Cost scales with region area. Small patches are very fast.
  • Poll interval is capped at 5000 ms here (tighter than other detection nodes), because the rules are cheap and meant to be sampled frequently.
  • changedSinceLastFrame holds the previous capture for comparison, so it costs one extra retained crop.

Memory notes

  • Every poll captures a fresh frame; frames are transient.
  • The change rule retains the previous poll's crop for the comparison — bounded by the region size, so keep regions small.

Common mistakes

MistakeWhat happensFix
Wiring only SuccessNot-passed ends the runWire Failure
Region too largeThe signal is averaged awaySmall, representative patch
Tolerance of 0Never passes on a real screenAllow slack
Using it to find an iconFragile and impreciseUse Find Image
Misreading the change rule"Settled" arrives on FailureWire it as the success path for settling
Expecting it to read a valueIt measures pixels, not textUse Read Text

Troubleshooting

It always passes. Tolerance is too wide, or the region includes so much variety that the average sits near your expected value regardless. Shrink the region.

It never passes. Tolerance is too tight. Widen it and confirm the measured value with Test Node.

The change rule always says "changed". The region includes a clock, an animated background, or a shimmer effect. Move it to a stable patch.

It exits Fatal. The region is invalid, or the expected value cannot be parsed for the chosen rule.

FAQ

Does a not-passed count as an error? No — the status stays success.

Can I check several regions in one node? No. Use one node per region, or use a multi-region Read Text if the values are textual.

What does changedSinceLastFrame compare against on the first poll? It needs a previous capture to compare with, so the comparison becomes meaningful from the second poll onwards.

Is this faster than Find Image? Yes, noticeably — no template matching is involved.

  • Find Image — when the target has a distinct appearance
  • Read Text — when you need the value
  • Wait — the blind alternative to a settle check
  • If — branch on this node's outcome later