Difference between revisions of "HPL3/Amnesia: Rebirth/Scripting/Scripting Api/Tool"

From Frictional Wiki
Jump to navigation Jump to search
(Created page with "{{ScriptingStub}} Have some helpful descriptions to add to this class? Edit this page and add your insight to the Wiki! ==Summary== {{CodeDocSummaryTop}} {{CodeDocSummaryIte...")
 
(No difference)

Latest revision as of 01:08, 16 November 2020

Have some helpful descriptions to add to this class? Edit this page and add your insight to the Wiki!

Summary

Return Type Function and Description
tString Tool_GetHandAnimationSuffix(const tString &in asName)
Returns the hand animation prefix specified for the tool
void Tool_PickUp(const tString &in asName, bool abEquipTool, bool abCallback)
Adds the specified tool to the player's inventory
void Tool_SetAutoHideAfterPickup(const tString &in asName, bool abX)
Sets if a tool should be hidden automatically after getting picked up and being displayed for a brief moment
void Tool_SetHighlightActive(const tString &in asName, bool abX)
Sets if a tool should have the highlight effect when looked at

Function Detail

Tool_GetHandAnimationSuffix

tString Tool_GetHandAnimationSuffix(const tString &in asName)

Returns the hand animation prefix specified for the tool.

Parameters

Returns:

  • tString—tString, the tool's hand animation prefix.

Tool_PickUp

void Tool_PickUp(const tString &in asName,
                 bool abEquipTool,
                 bool abCallback)

Adds the specified tool to the player's inventory. Similar to calling the entity interact on the tool entity, but with more control.

Parameters

  • asName (tString) —
  • abEquipTool (bool) —
  • abCallback (bool) —

Returns:

  • void

Tool_SetAutoHideAfterPickup

void Tool_SetAutoHideAfterPickup(const tString &in asName,
                                 bool abX)

Sets if a tool should be hidden automatically after getting picked up and being displayed for a brief moment

Parameters

  • asName (tString) —
  • abX (bool) —

Returns:

  • void

Tool_SetHighlightActive

void Tool_SetHighlightActive(const tString &in asName,
                             bool abX)

Sets if a tool should have the highlight effect when looked at.

Parameters

  • asName (tString) —
  • abX (bool) —

Returns:

  • void