Draggable
This component belongs to the following package:
- com.yahaha.sdk.horrorprops
The Draggable component enables an object to be moved by the player through dragging interactions.
Properties
- Interactive: Determines if the component is interactive. The component must be selected as an active plug-in in the Interactable component to function.
- Hint: A brief text to show on the screen, that indicates what the player could do. Default: "Inspect".
- Target Item: The target item to drag. Usually the item object has an Item Behavior component on it. Default: self.
- Mass: The Mass of the object.
- Surface Drag: Resistance to motion that a player would experience when dragging an object across a surface.
- No Lift-Up: Determines whether the object can be lifted. When enabled, the object cannot be picked up or raised. Default: Disabled.
Trigger
Events:
- com.yahaha.sdk.props.OnDragStart
- EventArgs: None
- com.yahaha.sdk.props.OnDragEnd
- EventArgs: None
Condition:
- CheckInteraction
- Description:
- Interact with prop, should call IsInteractice first
- Returns:
- result: boolean whether or not the interaction is success
- Description:
Action:
- IsInteractive
- Returns:
- param: table interactionParam
- Returns:
- Enable
- Description:
- Make the item interactive
- Description:
- Disable
- Description:
- Make the item non-interactive
- Description:
Related components
This component musted be used with Interactable, which enables player interaction with game objects.