Kelrugem
May 6th, 2019, 21:33
Hello :)
I need some help with adding effects via a code :) I have some prototype of an extension (I can somehow not add the link to it; it is in the 3.5e forum in the recent threads) which handles situation dependent saves. However, I found out that it only works for saves of NPCs but not for PCs. As far as I can see both are using the modSave function for effects in the manager_action_save.lua. My extension is based on adding an auxiliary effect to the person who has to roll the save using
local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor);
EffectManager.addEffect("", "", nodeActor, rEffectSpell, false);
(where rActor is the one making the save)
For NPCs that works, they get the effect rEffectSpell (in form of a string saved in rEffectSpell.sName). But for players this doesn't work. Does the addEffect works differently there? Or do I need a different command to get the node of a PC?
Thanks in advance :)
I need some help with adding effects via a code :) I have some prototype of an extension (I can somehow not add the link to it; it is in the 3.5e forum in the recent threads) which handles situation dependent saves. However, I found out that it only works for saves of NPCs but not for PCs. As far as I can see both are using the modSave function for effects in the manager_action_save.lua. My extension is based on adding an auxiliary effect to the person who has to roll the save using
local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor);
EffectManager.addEffect("", "", nodeActor, rEffectSpell, false);
(where rActor is the one making the save)
For NPCs that works, they get the effect rEffectSpell (in form of a string saved in rEffectSpell.sName). But for players this doesn't work. Does the addEffect works differently there? Or do I need a different command to get the node of a PC?
Thanks in advance :)