Vixen
caa30e12
csharp
public readonly record struct AbilityTarget

What an ability was aimed at, as whatever owns the world resolved it.

Read the guide page for this →

Remarks

⚠ The caller supplies the distance and this library never asks where anything is. Positions are Vixen.Engine's, and a combat library that needed a scene could not be tested without one, could not run in a headless simulation, and would drag a renderer's dependency into a realm. What it validates is the rule — that a targeted ability has a target and that the number the caller gave is inside the ability's range.

Fields and properties (5)

  • public GameplaySubject? Subject

    The thing aimed at, or null for a point or a shape.

  • public ulong Id

    Its number, as the caller numbers things.

  • public float Distance

    How far away it is, in metres.

  • public static AbilityTarget None

    Nothing selected.

  • public bool IsSome

    Whether anything is selected.

Methods (1)

  • public AbilityTarget(GameplaySubject? Subject, ulong Id, float Distance)

    What an ability was aimed at, as whatever owns the world resolved it.

Used by (5)

  • AbilityCasterVixen.Gameplay.Combat
  • AbilityCasterTestsVixen.Gameplay.Combat.Tests
  • AbilityEventVixen.Gameplay.Combat
  • CombatResolverVixen.Gameplay.Combat
  • CombatResolverTestsVixen.Gameplay.Combat.Tests