Endstar LUA API Documentation
Loading...
Searching...
No Matches
Interaction Class Reference

Used to create interaction behaviors for the NPCs. More...

Public Member Functions

void SetIsHeldInteraction (Context instigator, bool isHeldInteraction)
 Sets the interaction held behavior for the npc interaction.
 
void SetInteractionAnimation (Context instigator, InteractionAnimation interactionAnimation)
 Sets the interaction animation for the interaction.
 
void SetInteractionDuration (Context instigator, float duration)
 Sets the hold duration of a held interaction.
 
void StopInteraction (Context interactor, Context npcContext)
 Forces an interacting npc to stop interacting.
 
override void GiveInstruction (Context instigator, Context npc)
 Gives this instruction to the target npc.
 
override void RescindInstruction (Context interactor, Context npcContext)
 Rescinds the interaction instruction given to an npc.
 
void InteractionCompleted (Context interactor)
 Tells the interaction node that the player completed the interaction completely.
 
void InteractionCanceled (Context interactor)
 Tells the interaction node that the player canceled the interaction before fully completing it.
 
- Public Member Functions inherited from InstructionNode
Context GetContext ()
 Gets the context of this instruction node.
 
void SetContextBehavior (bool useContext)
 
Context GetNpcReference ()
 Gets the context of the referenced npc.
 
float GetTime ()
 Gets the current local game time.
 

Additional Inherited Members

- Properties inherited from InstructionNode
Endless.Gameplay.Scripting.InstructionNode ManagedNode [get]
 

Detailed Description

Used to create interaction behaviors for the NPCs.

Member Function Documentation

◆ GiveInstruction()

override void GiveInstruction ( Context instigator,
Context npc )
virtual

Gives this instruction to the target npc.

Parameters
instigatorThe context of the object instigating this action
npcThe npc to give this instruction to

Reimplemented from InstructionNode.

◆ InteractionCanceled()

void InteractionCanceled ( Context interactor)

Tells the interaction node that the player canceled the interaction before fully completing it.

Parameters
interactorThe context of the interactor

◆ InteractionCompleted()

void InteractionCompleted ( Context interactor)

Tells the interaction node that the player completed the interaction completely.

Parameters
interactorThe context of the interactor

◆ RescindInstruction()

override void RescindInstruction ( Context interactor,
Context npcContext )
virtual

Rescinds the interaction instruction given to an npc.

Parameters
interactorThe interactor involved in the interaction
npcContextThe npc to rescind the instruction for.

Reimplemented from InstructionNode.

◆ SetInteractionAnimation()

void SetInteractionAnimation ( Context instigator,
InteractionAnimation interactionAnimation )

Sets the interaction animation for the interaction.

Parameters
instigatorThe source context triggering this change
interactionAnimationThe interaction animation to set

◆ SetInteractionDuration()

void SetInteractionDuration ( Context instigator,
float duration )

Sets the hold duration of a held interaction.

Parameters
instigatorThe source context triggering this change
durationThe duration of the held interaction.

◆ SetIsHeldInteraction()

void SetIsHeldInteraction ( Context instigator,
bool isHeldInteraction )

Sets the interaction held behavior for the npc interaction.

Parameters
instigatorThe source context triggering this change
isHeldInteractionThe value of the new held interaction bool

◆ StopInteraction()

void StopInteraction ( Context interactor,
Context npcContext )

Forces an interacting npc to stop interacting.

Parameters
interactorThe interactor involved in the interaction
npcContextThe npc to stop interacting/