HoverableOutline

This component is originally from https://github.com/chrisnolet/QuickOutline and adapted.

If a runtime unit (RtUnitBhv) should be (able to be) outlined at runtime, add this component to the unit prefab.

When will a unit be outlined

  • First of all the Hoverable Outline component must be present.

  • The component must be placed (in the GameObject hierarchy) so that it finds one or more meshes to outline. As a debugging aid, it will show you (at runtime) how many meshes it found (Num Meshes). If this number is zero, no meshes where found and nothing will be outlined. The component will search for renderers in its GameObject and children.

  • A unit is regarded as non-hoverable if at least one of the Unit State Flags "Unselectable" or "Untargetable" is true.

Selecting what should be outlined

If one or more meshes you want to outline are on children of the object, you must check the box "Also Children".

You may also add this component to one of the child GameObjects inside the prefab. That way you can exactly control which meshes are considered for outlining. This is useful because you do not want the outline to include anything like particle systems that get added to the unit at runtime (e.g. through a buff).

There is also the component OutlineSkip. Place this beside every Renderer component that you want to skip.

Outline Color

The Outline Color can be configured in the TbeSceneSettings under "Alignment Coloring".