InteractionLifecycleEventArgs
Namespace: FireSoftworks.Interaction
Type: Class
Assembly: FireSofworks.InteractionSystem
Payload for IInteractor.InteractionStarted and IInteractor.InteractionEnded C# events, and the corresponding onInteractionStarted / onInteractionEnded UnityEvents.
public class InteractionLifecycleEventArgsConstructor
public InteractionLifecycleEventArgs(IInteractable target)Fields
Target
public readonly IInteractable Target;The interactable involved in the lifecycle event.
Usage
interactor.InteractionStarted += (InteractionLifecycleEventArgs args) =>{ highlightOutline.Enable(args.Target.GetGameObject()); crosshair.SetInteractState(true);};
interactor.InteractionEnded += (InteractionLifecycleEventArgs args) =>{ highlightOutline.Disable(); crosshair.SetInteractState(false); hud.HideActionMenu();};