Prop
This component belongs to the following package:
- com.yahaha.sdk.props
The Prop component enables an object to become an interactive prop in gameplay.
Properties
- Interactive: Determines if the component is interactive. The component must be selected as an active plug-in in the Interactable component to function.
- Action: The input action (or key) that triggers the interaction.
- Hint: A brief text displayed on-screen to guide the player. Default: "Inspect".
- Required Item: The name of the item (from item slots) that can be inserted into this socket. The item has an Item Behavior component attached.
- Repeatable: Determines whether this object can be interacted with multiple times. Disabled by default.
Trigger
Events:
- com.yahaha.sdk.props.OnPropInteracted
- EventArgs:
Action:
- IsInteractive
- CheckInteraction
- Description:
- Interact with prop, should call IsInteractice first
- Enable
- Description:
- Make the item interactive
- Description:
- Disable
- Description:
- Make the item non-interactive
- Description:
- SetHint
- Arguments:
- hint: string
- Arguments:
- Interact
Related components
This component must be used with Interactable, which enables an object to become interactive.