Guide/Settings

Conditions

Conditions lets you write your own rules: when this happens, do that. For example: "when my shield is under 40%, fire SAB" or "when a player attacks me, switch to config 2".

It's a behaviour, so it works with any module. Find it in your config under Behaviours → Conditions.

Conditions with no rules yet, showing the examples to start from

Make your first rule

The easiest way is to start from an example.

  1. Open Conditions and switch it on.
  2. Under No rules yet. Start from one of these:, click the example closest to what you want, like Big NPCs get better ammo.
  3. The rule opens. Change any number or choice you like.
  4. Save it. The rule appears in the list, switched on.

+ New rule opens the same examples; to build one from nothing, pick the Blank rule tile.

How a rule is built

Every rule has two parts:

  • 1. When: one or more things that must be true. My shield is under 40%, my target is an NPC, I'm on a PvP map…
  • 2. Do: what to do while they are true. Fire SAB, use the Turtle formation, switch to config 2…
Good to know

When the condition stops being true, the bot goes back to what it was doing. You don't need a second rule to switch back.

Every rule can also have an Otherwise part (+ Otherwise…): what to do the whole time the rule is false.

Under the editor, LeanBot writes your rule out as a sentence, so you can check it says what you meant.

A few more ways to build one:

  • Until: press ⇥ on a row to keep it on until something else is true: my hull is below 70%, until it is above 99%.
  • Chain rules: the Another rule → Rule is on condition is true while another of your rules is on.
  • Compare two readings: instead of a number, compare with another live reading: my hull % is below my target's hull %.
  • Paste: use the paste link under the conditions and paste a condition written as text; it replaces the conditions above.

Things a rule can check

AboutExamples
MeHull or shield %, nano hull, the most hull, shield or nano hull the ship can have, in a fight, being repaired, under attack, attacked by a player / an enemy / an NPC (or one by name), in a safe zone, cargo %, ability ready, how many of an item I have, cloaked, going to safety, distance to a point on the map
My targetHave a target, is an NPC, name contains…, its most hull or shield, distance, its priority in the NPC table, is an enemy, the group is shooting it, has tag A/B/C
Around meNPCs / players / enemies nearby, an NPC or player by name nearby
PETPET is out, PET hull %, PET heat %, PET fuel
GroupA member's hull or shield, I'm the leader, group size
The worldWhich map, PvP map, time of day, deaths this run, a gate ahead, what this run has earned, your balance, how long the bot has run
Another ruleRule is on

Things a rule can do

Laser ammo · Formation · Ship config · PET gear · PET out or in · Use a ship ability · Use an item · Rocket · Shoot the group's target · Leave tagged NPCs alone

Leave tagged NPCs alone keeps the bot off the NPCs you tagged A, B or C in your NPC table for as long as the rule is true, even one it is already fighting. For example, tag Strokelight with Tag A, then: when my hull % is below 85, leave NPCs tagged A alone. It works in Kill & Collect and NPC Killer. Gates and the Black Light hunters ignore it: every NPC in a gate has to die.

When two rules want the same thing

The higher rule wins. Drag rules up and down with the ⠿ handle, or use the arrows. Each rule also has a switch to turn it off without deleting it, and buttons to duplicate or delete it.

Example ideas

  • SAB when my shield is low: drain the target's shield to refill yours.
  • Cheaper ammo when MCB-50 runs low: stop spending the last of it.
  • Better ammo on tagged NPCs: tick Tag A on the NPCs worth it in the NPC table.
  • ISH when a player attacks me.
  • Shoot what the group shoots.
Still stuck?Ask on our Discord. Say what you pressed and what happened, and send the newest log file (the Logs button in LeanBot's title bar).
Ask on Discord