Table of Contents
Option 1: Highlighting/customizing a SINGLE sprite
– Add HighlightEffect2D.cs script to any sprite. Customize the appearance options.
– Optionally add HighlightTrigger2D.cs script to the sprite GameObject. It will activate highlight on the sprite when mouse pass over it. Note that a collider must be present on the sprite. Note: adding a HighlightTrigger2D script to a sprite will automatically add a HighlightEffect2D component.
Option 2: Highlighting/customizing ANY sprite automatically
– Select top menu GameObject -> Effects -> Highlight Plus 2D -> Create Manager.
– Customize behaviour of Highlight Manager 2D. If a sprite already has a HighlightEffect component, it will use those settings instead.
Option 3: Highlighting specific sprites using scripting
After adding the Highlight Effect component to your sprite, use GetComponent<HighlightEffect2D> and set the “highlighted” property of the component to true.
Ignoring specific sprites from highlighting
Add a HighlightEffect2D component to the sprite and activate the “Ignore” checkbox under Highlight section.
Highlighting single vs group of sprites
Use the “Include” setting in the inspector to specify if you want to include the children sprites when this one is highlighted. By default, highlight plus will include all children but you can restrict this to only highlight this one.
Note that if any children has its own Highlight Plus 2D component, it won’t be included with the parent.
Exclusive and grouped outline effects
By default, Highlight Plus combines outline of overlapping sprites. If you want certain sprites to preserve their own outline you have two options:
Enable the “Exclusive” toggle under the Outline section. That will make the outline to show independently for that sprite.
Add a HighlightGroup2D component to the sprites in a group and assign a group number (ie. “1”). Group 0 does not do anything. The outlines of that group will not be combined with other sprites, only among sprites of the same group.