RemoveSpell and OnEffectFinish

Post » Tue Jun 19, 2012 7:24 pm

I read all the wiki documentation I could find on the above, but it didn't answer my question. Does anyone know if OnEffectFinish is called when RemoveSpell is called? Really what I'm getting at is I want to learn all the instances where OnEffectFinish is called. Is it only when a magic effect times out? Is it called when Dispel() is called? If no one knows, I'll just go do some trial and error in the CK and let everyone know what my results were. Thanks.
User avatar
Noely Ulloa
 
Posts: 3596
Joined: Tue Jul 04, 2006 1:33 am

Post » Tue Jun 19, 2012 5:40 pm

Nitor,

Did you find any info about this? I have some spells where OnEffectFinish does not get fired (consistently). Channelling spells where the player casts the spell but quickly releases it just after casting, and one where the spell is applied through a constant effect but has a condition. I cannot reproduce the latter issue but I can the channelling issue. I know users of my mod are experiencing this problem and wonder if it has something also to do with the "speed" of their systems.

-MM
User avatar
john page
 
Posts: 3401
Joined: Thu May 31, 2007 10:52 pm

Post » Tue Jun 19, 2012 7:46 pm

I read all the wiki documentation I could find on the above, but it didn't answer my question. Does anyone know if OnEffectFinish is called when RemoveSpell is called? Really what I'm getting at is I want to learn all the instances where OnEffectFinish is called. Is it only when a magic effect times out? Is it called when Dispel() is called? If no one knows, I'll just go do some trial and error in the CK and let everyone know what my results were. Thanks.



In addition to a magic effect timing out, DispelSpell(), also causes OnEffectFinish to trigger.

Removing a spell from the player does not cause OnEffectFinish to trigger.
User avatar
Brandi Norton
 
Posts: 3334
Joined: Fri Feb 09, 2007 9:24 pm

Post » Tue Jun 19, 2012 9:12 pm

heilghast,

Are there any other conditions that cause OnEffectFinish to not trigger consistently. I have a spell that I know it's not firing consistently for some, but for me it's always consistently fired on this spell. I do not rely on removing the spell, the MGEF is applied based on a condition on the spell itself.

-MM
User avatar
Kim Bradley
 
Posts: 3427
Joined: Sat Aug 18, 2007 6:00 am

Post » Wed Jun 20, 2012 2:59 am

I haven't come across any so far.
I replied as i have been working on a spell which involves using dispelspell and removespell on OnEffectFinish.
User avatar
Terry
 
Posts: 3368
Joined: Mon Jul 09, 2007 1:21 am

Post » Wed Jun 20, 2012 1:57 am

OnEffectFinish will fire if RemoveSpell is used on an ability that is currently affecting the actor

just tested it with a very simple script-ability set up
heres the script if you'd like to test it for yourself
Scriptname csdTest1 extends activemagiceffectspell property csdAb autoEvent OnEffectStart(Actor akTarget, Actor akCaster)  RegisterForSingleUpdate(10.0)EndEventEvent OnUpdate()  Game.GetPlayer().RemoveSpell(csdab)EndEventEvent OnEffectFinish(Actor akTarget, Actor akCaster)  debug.MessageBox("Removed!")EndEvent

I added an ability to the player via console with a magic effect that had that script attached. 10 seconds later the messagebox popped.
User avatar
Natasha Biss
 
Posts: 3491
Joined: Mon Jul 10, 2006 8:47 am

Post » Wed Jun 20, 2012 1:11 am

Csscottydont, check out this thread, http://www.gamesas.com/topic/1381389-oneffectfinish-does-not-always-fire and let me know if you have any ideas on why the oneffectfinish doesn't fire consistently for some users.
User avatar
adame
 
Posts: 3454
Joined: Wed Aug 29, 2007 2:57 am

Post » Wed Jun 20, 2012 12:43 am

Yeah, sorry I didn't follow through on this one. I came to the same conclusions you all did.
User avatar
Reven Lord
 
Posts: 3452
Joined: Mon May 21, 2007 9:56 pm

Post » Tue Jun 19, 2012 9:25 pm

No, removespell does not even remove the magic effect unless the spell is.a ability. The wiki really mea when a magic effect is removed using dispelspell, not when the spell.is taken away from the actor using removspell (except in the case where the spell is a constant effect self spell as mentioned before.)
User avatar
Matt Terry
 
Posts: 3453
Joined: Sun May 13, 2007 10:58 am


Return to V - Skyrim