eq2emu/docs/lua_functions/SetSpellDisplayEffect.md

29 lines
792 B
Markdown
Raw Permalink Normal View History

2025-05-25 21:42:32 -04:00
### Function: SetSpellDisplayEffect(spell, idx, field, percentage)
2025-05-04 14:34:15 -04:00
**Description:**
2025-05-25 21:42:32 -04:00
Set's the spell display effect value.
2025-05-04 14:34:15 -04:00
**Parameters:**
2025-05-25 21:42:32 -04:00
- `spell` (Spell) - Spell object representing `spell`.
- `idx` (uint32) - Integer value `idx`.
- `field` (string) - String `field`.
- `percentage` (uint8) - Integer value `percentage`.
2025-05-04 14:34:15 -04:00
**Returns:** None.
**Example:**
```lua
2025-05-25 21:42:32 -04:00
-- From ItemScripts/AbbatoirCoffee.lua
function cast(Item, Player)
Spell = GetSpell(5463)
Regenz = 18.0
newDuration = 180000
SetSpellData(Spell, "duration1", newDuration)
SetSpellData(Spell, "duration2", newDuration)
SetSpellDataIndex(Spell, 0, Regenz)
SetSpellDisplayEffect(Spell, 0, "description", "Increases Out-of-Combat Power Regeneration of target by " .. Regenz)
CastCustomSpell(Spell, Player, Player)
end
2025-05-04 14:34:15 -04:00
```