Difference between revisions of "LlAdjustDamage"

From Second Life Wiki
Jump to navigation Jump to search
(Created page with "{{LSL_Function |func_id=|func_sleep=0.0|func_energy=10.0 |func=llAdjustDamage|return_type= |p1_type=integer|p1_name=number|p1_desc=The index of the damage event to be modified...")
 
(No difference)

Latest revision as of 12:50, 21 March 2024

Summary

Function: llAdjustDamage( integer number, float new_damage );

The llAdjustDamage modifies the amount of damage that will be applied by the current on_damage event after it has completed processing.

• integer number The index of the damage event to be modified.
• float new_damage A new damage value to be applied or distributed after on_damage processing.

Specification

KBwarning.png Warning: This function or parameter is part of the Combat2 project and is only available on parts of the beta grid.

This function allows a script to modify incoming damage before it is applied to an avatar or distributed by a task.

Caveats

  • Calling this function from any event handler other than on_damage results in an error message being shouted to the debug channel.
  • Negative indexes are not supported.
  • Indexes that are out of range will silently fail.
All Issues ~ Search JIRA for related Bugs

Examples

See Also

Events

•  on_damage

Functions

•  llDetectedDamage

Deep Notes

Search JIRA for related Issues

Signature

function void llAdjustDamage( integer number, float new_damage );