llms.txt: machine-readable documentation index. Markdown version of this page is also available.

Ninja Bear Studio Plugins Help

Make a Guard Respond to Threat

Give a fighter and a healer threat with the same guard, then watch which actor the guard senses. Start with the guard from First Steps. This example uses explicit Blueprint calls so you can try it before you have working combat or healing abilities.

Give the guard a Threat Manager and a Threat Sense

  1. Create a Blueprint child of the guard's Ninja Bot AI Controller and add a Ninja Bot Threat Manager Component. Set the guard's AI Controller Class to that Blueprint.

  2. Duplicate the guard's Bot Setup and Sense Profile for this test. In the copy of the profile, use AI Threat Sense Configuration as the only sense and set Threat as the Dominant Sense. Give it a short Max Age, such as 3 seconds, so you can see each test signal expire.

  3. Assign the copied profile to Perception Sense Profile on the copied setup, and have the test guard return that setup. Use the First Steps chase condition that checks Sensed Actor.

Give two actors competing scores

  1. Place two characters near the guard and label them Fighter and Healer in the Outliner. In the Level Blueprint, create references to the guard and both characters.

  2. For a single-player test, add three keyboard events to the Level Blueprint. On each press, get the guard's Controller, then Get Component by Class for the Threat Manager. Call Register Threat Source on that component.

  3. Wire the first key to register Fighter with 10 threat. Wire the second and third keys to register Healer with 6 threat each. Use one press per key. For a networked game, make these calls from the server.

Try It in Play

Select the running guard in the tree debugger and watch Sensed Actor. Press the first key. Fighter should appear as the guard's target. Press the second key. Healer has 6 threat, so Fighter still leads and the manager sends no new signal. Let the first stimulus expire and the target clear, then press the third key. Healer now has 12 threat and should appear as the new target. The first signal expiring did not erase Fighter's 10 threat.

If neither actor appears, check that the placed guard uses your controller and the copied Sense Profile. Once the test works, restore Sight to the profile and repeat. Sight and threat can now favor different actors. Adjust the sense weights and target-switch settings to get the behavior your encounter needs. See Threat and Target Priority for damage-driven threat and per-actor modifiers.

25 November 2026