Jump to content

Add AI Package to NPC dynamically (by casting spell on them)


Recommended Posts

Posted

Hi! SO I want to add an AI package to NPCs dynamically, by casting spell on them. To do this I created a quest that reacts to a spell casting. Then I added an alias reference for the actor that a spell is cast on, and for that alias I added an AI package, in this case to make them follow me.

However this does not work in the game when I cast spells on NPCs. Am I missing some steps? I have to say I'm pretty new with the aliases and they kind of really confuse me. So I'm not sure I did this right.

Posted

Hi! SO I want to add an AI package to NPCs dynamically, by casting spell on them. To do this I created a quest that reacts to a spell casting. Then I added an alias reference for the actor that a spell is cast on, and for that alias I added an AI package, in this case to make them follow me.

However this does not work in the game when I cast spells on NPCs. Am I missing some steps? I have to say I'm pretty new with the aliases and they kind of really confuse me. So I'm not sure I did this right.

 

Try increasing the priority of the quest otherwise it may just be another package. Also try using sqv <quest> or sqv <quest script> to see if the alias was filled properly by the spell.

Posted

 

Hi! SO I want to add an AI package to NPCs dynamically, by casting spell on them. To do this I created a quest that reacts to a spell casting. Then I added an alias reference for the actor that a spell is cast on, and for that alias I added an AI package, in this case to make them follow me.

However this does not work in the game when I cast spells on NPCs. Am I missing some steps? I have to say I'm pretty new with the aliases and they kind of really confuse me. So I'm not sure I did this right.

 

Try increasing the priority of the quest otherwise it may just be another package. Also try using sqv <quest> or sqv <quest script> to see if the alias was filled properly by the spell.

 

Thanks for the reply! It seems like the problem lies in that the quest doesn't want to start on given event that i choose. It works if I choose start game enabled. But for ex if I select "actor dialogue event", the quest does not start when I initiate dialogue with an NPC. Am I missing something here?

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...