![]() |
SpellEffect - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: General Help (/Forum-General-Help) +--- Thread: SpellEffect (/Thread-SpellEffect) |
SpellEffect - Art - 05-13-2013 06:31 AM Code: ON=@SpellEffect I have that script for my own magic reflection system. When i cast spell to target, damage blocked and spell going back like it should, but there is a problem, 'The spell fizzles' appears, also if both players have Magic Reflection, caster will take spell effect with that message 'The spell fizzles'. But in theory, target should take effect. RE: SpellEffect - Wap - 05-13-2013 09:14 AM You want to make a possibility of double reflect? RE: SpellEffect - Alaric - 05-13-2013 09:22 AM Sphere wiki Wrote:SPELLEFFECT spell_id, strength, source_character_uid, source_item_uid Btw. are you sure you want situation like: PL1 and PL2 have reflextions, both. PL1 casts fire ball, it reflects from PL2 back to PL1 and from PL1 it reflexts again to PL2 who is finally hit by the spell? Hope, I understood, what you ment. RE: SpellEffect - Art - 05-13-2013 02:35 PM PL2 will be hit by spell, because he doesn't have Magic Reflection anymore after first reflect. RE: SpellEffect - Rattlehead - 05-13-2013 02:43 PM i may be wrong, but when u return 1 it will cause fizzle to display RE: SpellEffect - Art - 05-13-2013 02:53 PM No, the fizzle caused by 'src.spelleffect' function back to caster. But seems like caster will have new spell effect before trigger @SpellEffect on target will be done. Target already reflected spell to caster, but caster still receive fizzle message and sound. I need correct solution =\ RE: SpellEffect - Rattlehead - 05-14-2013 10:02 AM what i mean, is that returning 1 cancels most things on triggers, spelleffect is kind of a twitchy trigger, so my comment meant that returning 1 on the targets spelleffect may make the server think the spell was canceled (as it should btw) and thus displaying the fizzle message on caster (as the server thinks the spell failed), of course i could be wrong as i have nvr tried it myself. since your trigger sends said effect back to caster when the trigger fires, then even tho the spelleffect was canceled via return 1, it still sends it back regardless, so everything will still function as intended. an easy way to test this is to return 0 on spelleffect to see if the fizzle still occurs, but keep in mind that returning 0 will cause the target to receive the hit still and i know thats not what you intended but it will work for a test just to verify if the return is what is causing it, i dont know if return 2 will work as an alternative method but you could try it. |