Author Topic: Get Familiar casting spell?  (Read 315 times)

Legacy_BelowTheBelt

  • Hero Member
  • *****
  • Posts: 699
  • Karma: +0/-0
Get Familiar casting spell?
« on: February 18, 2014, 08:23:54 pm »


               What's a way for me to determine if a familiar is casting a spell (rather than the PC)?

I put in a GetIsPC check in a spellhook script that, if false, should return the script.  But  in the case of a familiar, it doesn't seem to be triggering false and instead is getting past the check and triggering a subroutine that should only affect PCs.

Ultimately, I want to know if the caster of a spell is a familiar (or companion or henchman).

Any thoughts or a place to start?
               
               

               


                     Modifié par BelowTheBelt, 18 février 2014 - 08:24 .
                     
                  


            

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0
Get Familiar casting spell?
« Reply #1 on: February 18, 2014, 08:29:01 pm »


               GetIsPC should return FALSE for the familiar, however player can possess the familiar and in that case GetIsPC returns TRUE. To deal with this try GetIsPossessedFamiliar() which returns TRUE if the oTarget is player-possessed-familiar.

You are in the suitable place already.
               
               

               


                     Modifié par ShaDoOoW, 18 février 2014 - 08:29 .
                     
                  


            

Legacy_BelowTheBelt

  • Hero Member
  • *****
  • Posts: 699
  • Karma: +0/-0
Get Familiar casting spell?
« Reply #2 on: February 18, 2014, 09:12:37 pm »


               Excellent.  Thanks.  The PC was seeing feedback messages, so was probably possessing the familiar to do the casting.