UtilityAI & Scoring System


Reachable in-editor from Tools > Utility AI > Documentation. ... SUPPORT ... WHY SCORING INSTEAD OF A TREE ... Programmers get the same engine as a strongly typed C# API for scoring their own ...


by PostanteGames


Price History +

Score-based AI decisions for NPCs: every option rates itself 0-1, best score wins. No-code component, 15 considerations, live score debugging, full C# source, no dependencies.

FEATURES


• No-code authoring - the Utility Brain component scores GameObjects with no scripts at all.

• 15 built-in considerations - Distance, Angle (field of view), Line Of Sight, Normalized Stat, Threshold, Range, Age, Cooldown, Affordability, Capacity, Equality, Bool From Context, Random Noise, Inertia, Constant.

• Hard filters - a requirement that rejects a candidate outright, kept separate from preferences that merely lower its score.

• Response curves - Linear, Quadratic, their inverses, Logistic, Threshold, Constant, or your own AnimationCurve, per consideration.

• Five combiners - Multiplicative (a full-weight zero vetoes), Average, Sum, Min, Max.

• Five tie-break policies - First In List, Last In List, Random, Prefer Current (stops flip-flopping), All Winners.

• Candidate sources - a hand-filled list, a tag, a radius, or this object's children.

• Live debugging - per-candidate score breakdowns consideration by consideration during Play, plus rule validation and candidate diagnostics that name the object at fault.

• Strongly typed C# API - RuleBuilder<T>, ScoringEngine, asset factories and a registry, for scoring your own types instead of GameObjects.

• Four authoring windows - unified Editor workspace, Rule Builder, Playground, Score Debugger.

• Optional bridges - PostanteGames StatSystem and TaskSystem activate automatically if present, with no dependency in either direction.

• Five AI assistant skills - task-scoped instructions your AI coding assistant follows to author rules, set up scenes, script against the API and debug decisions.

• Full C# source, no DLLs, no third-party runtime dependency.

• Five demo scenes, complete XML documentation on the whole public API, and 479 EditMode tests.


UNITY VERSIONS


Unity 6 ready, and works back to Unity 2021.3 LTS. Verified on both ends - 2021.3.45f2 and 6000.7 - with every test green on each.


RENDER PIPELINES


Built-in, URP and HDRP. The plugin is pure C# with no shaders or materials of its own; the demo scenes build their visuals from whatever pipeline your project uses.


SUPPORTED OS


The package is pure C#. It contains no native plugins, no DLLs, no platform invokes and no platform-specific code, so the editor tools run wherever the Unity Editor runs - Windows, macOS and Linux - and builds run on every platform Unity targets. Development and testing were done on Windows, including 64-bit player builds on both Mono and IL2CPP.


DOCUMENTATION


Included in the package as Markdown (English and Turkish): Getting Started, No-Code Guide, Scripting Guide, Reference, Troubleshooting - plus a printable RTF user manual. Reachable in-editor from Tools > Utility AI > Documentation.


Online manual: https://postante.com/dokumanlar/utility-ai/getting-started


SUPPORT


PostanteGames@gmail.com, and the Discord invite in the package README.


Utility AI replaces sprawling if-else chains and hand-tuned behavior trees with something a designer can actually reason about: every option scores itself from 0 to 1, and the best score wins. Add a consideration, watch the numbers move, ship.


WHY SCORING INSTEAD OF A TREE


A behavior tree makes you encode priority as structure, so every new rule means restructuring the graph. Scoring keeps priority as data. "Prefer close targets, but never shoot through a wall, and don't flip-flop between two equally good ones" is three considerations, not a re-plumbed tree.


WORKS WITH NO SCRIPTS AT ALL


Drop the Utility Brain component on an object, pick a rule asset, pick where candidates come from - a list, a tag, a radius, or this object's children - and press Play. Designers tune weights and curves in the Inspector while the game runs. Programmers get the same engine as a strongly typed C# API for scoring their own types, not just GameObjects.


YOU CAN SEE WHY IT DECIDED


The Rule Editor breaks every candidate's score down consideration by consideration while the game is running, so a wrong decision is a number you can look at instead of a guess. Rule validation and candidate diagnostics name the object at fault, and every error the plugin prints says what it was doing at the time.


FIVE DEMO SCENES, FOUR OF THEM RETUNABLE


Village Defense is a playable micro-game where bad rules genuinely lose the tower. Target Selection, Job Board and Consideration Lab each isolate one idea and let you drag the weights while they run. A hub scene navigates between them in one click.


BUILT TO SIT BESIDE YOUR OTHER TOOLS


Works on its own, and works better together: if you own PostanteGames StatSystem, Utility AI reads real runtime stats as decision inputs; if you own TaskSystem, the decisions it makes become real queued tasks. Both bridges activate automatically and neither is required - there is no dependency in either direction.


Full C# source, no DLLs, no third-party runtime dependency. English and Turkish documentation. 479 EditMode tests, all green.