getPickupAmount
Client-side
Server-side
Shared
This page is incomplete! Help wanted!
Please finish this page using the corresponding Old Wiki article.
Go to Contribution guidelines for more information.
This function retrieves the amount of health or armor given from a pickup.
Syntax
getPickupAmount ( )Code Examples
server
function onPickupHitFunction ( thePlayer ) if getPickupType ( source ) == 0 then -- check the type of pickup, if it is a health pickup then amount = getPickupAmount ( source ) outputChatBox ( "You picked up " .. amount .. " health", thePlayer) endendaddEventHandler ( "onPickupHit", root, onPickupHitFunction ) -- add an event handler for onPickupHit