Seeing is Believing - Multiple Spell Fixes
This fixes/implements the following spells:
Cast Sight Bind Sight Eye of Zomm Eye of Tallon Stalking Probe (Gnomes Rejoice!) I used #summonitem to grab a tinkered stalking probe and holgresh elder beads and they both right clicked properly. Here is the Diff: Code:
--- E:\EQEmu827\zone\spdat.h Mon Jul 10 22:43:22 2006 * Change 189041 in all querys to an npc id of your choice if mine conflicts: Code:
INSERT INTO aa_swarmpets (spell_id, `count`, npc_id, duration) VALUES ( 323,1,189041,0); Enjoy :) |
Nice work =)
Tell your wife we say Happy Birthday too =) |
gah, IsBeneficialSpell() is getting messy already.... but I havent seen a better solution, so we deal with it. A minor style thing, please do not use unbracketed {} if's which span more than one line, it can make code tricky to read.
I ended up rewritting a lot of the code to accomplish two things: - Instead of checking for specific spell IDs in the temp pet function, I extended the temp pet interface to allow for the flexibility needed for this usage. (I disagreed with your statement that we do not set the eye's owner, did you have a concrete reason for doing that?) - You have to be careful with memory when you create new NPCType objects, as the ones from database.GetNPCType come from shared memory, and you allocated a new one on the heap, you have to make sure to tell the NPC object about that. Look at the code to see the details. SQL syntax fixed (same errors as last time), and ID changed for PEQ. BTW, the "official" raneg of IDs for pets is between 500 and 999. Code:
INSERT INTO aa_swarmpets (spell_id, `count`, npc_id, duration) VALUES ( 323,1,644,0); |
I didn't want to assign the eye an owner so that if the eye was hit by an AE spell it wouldn't add it's Owner to the AE casters hate list. Nothing that happens to the eye should reflect on the player that cast the eye and I was afraid giving the eye an OwnerID could trip code paths that it shouldn't or doesn't need to.
|
well hate works the other way... so theoretically the owner would get the caster of the AE added to its hate list, which would be correct if for some reason an NPC cast the eye, and you killed it... it would be mad at you. I think its better to set the owner and see what comes of it.
|
All times are GMT -4. The time now is 08:09 PM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.