🏹
Unit Formation
  • WELCOME
    • πŸ‘‹Hello
    • πŸ—ΊοΈRoadmap
    • ⛑️Support & Community
    • πŸŽ“Changelog
  • GETTING STARTED
    • πŸ”ŒImport package
    • βš’οΈAdd unit placement to scene
    • 🚢Add unit movement
    • πŸ“½οΈPosition units in Editor
  • HOW IT WORKS
    • πŸ‘‡Formation Placement
    • πŸ¦₯Unit Formation
    • πŸ“ΊPlacement Visuals
    • πŸ–±οΈInput
    • 🎽Formations
  • Integrations
    • 〽️A* Pathfinding Project
      • πŸ”ŒImport package
      • βš’οΈAdd unit placement to scene
      • 🚢Add unit movement
      • πŸ“½οΈPosition units in Editor
Powered by GitBook
On this page
  • Intro
  • Provided visuals
  • Direction Line
  • Formation Positions
  • Customisation
  1. HOW IT WORKS

Placement Visuals

Detailed information about how visuals are shown to the player and how to create your own.

PreviousUnit FormationNextInput

Last updated 1 year ago

Intro

These features are optional and placement is possible without any visuals.

Provided visuals

Direction Line

Using the provided LinePlacementVisual component, you can render direction with LineRenderer with two points, start and finish. The component only manages the renderers state, for customisation of line visuals, configure LineRenderer component to change its thickness, material, shadow and more.

Formation Positions

When UnitPlacement has enabled alwaysCalculatePositions, then you can also use FormationIndicatorVisual component to show positions of unit formation while player is placing the new position and direction of the formation.

To use this component you need to specify:

  • Unit Indicator Prefab used for unit position indicator in a formation

  • Hide with delay enable and specify delay if formation indicators should persist after placement is no longer active.

Customisation

APlacementVisuals is a component for utilising visuals when placing a formation in world environment with FormationPlacement. This can be extended to support any type of visuals.

Look for APlacementVisuals in project to get full information about how this one communicates with the placement component. Once you implement your own, add it to the list of visual renderers on FormationPlacement component and you're good to go!

πŸ“Ί
Add Line Placement Visual
Formation Indicator Visual