Unity RTS Engine

  1. Home
  2. Unity RTS Engine
  3. Units
  4. Invisibility Component

Invisibility Component

When the “Invisibility.cs” component is added to the main unit’s object, it allows the unit to go invisible for some time:

  • Invisibility Duration: For how long will the unit stay invisible?
  • Affected Materials: The materials that will have their Alpha Color changed when the unit is invisible.
  • Alpha Color: The alpha color of the above materials value (must be between 0 and 1 with 0 being completely invisible and 1 being completely visible).
  • Go Invisible Sprite: The sprite of the task that allows the unit to go invisible.
  • Go Visible Sprite: The sprite of the task that allows the unit to go visible.
  • Go Invisible Audio: Audio clip played when the unit goes invisible.
  • Go Visible Audio: Audio clip played when the unit goes visible.
  • In the “While invisible” list, set what this unit can still when it is invisible (can it attack other units?, construct buildings?, etc..). Please note that the unit can not be attacked when invisible.

How can we help?