Dedication to Action and fun.
 
HomeCalendarFAQSearchMemberlistUsergroupsRegisterLog in

Share | 
 

 Copy the last action of a PC

Go down 
AuthorMessage
lolthatguy

avatar

Posts : 290
Join date : 2013-05-05
Age : 24
Location : larry town

PostSubject: Copy the last action of a PC    Sun Feb 21, 2016 12:01 pm

kind of a strange question, but is there a way to set an AI to reciprocate the last action of a PC?

so basically if a PC chooses to buff a defensive buff , the NPC will copy that move, if it falls under one of the spells it can cast itself.

If a PC opts for an offensive option then the NPC will follow through and do the same.

I want to see if it can do this so that the NPC wont get duped over and over again by the same move.
Back to top Go down
View user profile
Highv Priest
Admin
avatar

Posts : 615
Join date : 2012-09-13

PostSubject: Re: Copy the last action of a PC    Sun Feb 21, 2016 11:17 pm

lolthatguy wrote:
kind of a strange question, but is there a way to set an AI to reciprocate the last action of a PC?

so basically if a PC chooses to buff a defensive buff , the NPC will copy that move, if it falls under one of the spells it can cast itself.

If a PC opts for an offensive option then the NPC will follow through and do the same.

I want to see if it can do this so that the NPC wont get duped over and over again by the same move.

Offensive is easy, just use OnSpellCastAt event for the NPC. Defensive is harder, you have to use the server's spell hook, do a hostility check(to get only defensive spells), make sure the.target is the player and not somethong else and then have the spellhook relay the spell used to the NPCs nearby that would react to it.
Back to top Go down
View user profile http://badlandsaction.forumotion.com
lolthatguy

avatar

Posts : 290
Join date : 2013-05-05
Age : 24
Location : larry town

PostSubject: Re: Copy the last action of a PC    Mon Feb 22, 2016 9:12 am

ahh ok, I'll try that. thanks
Back to top Go down
View user profile
Sponsored content




PostSubject: Re: Copy the last action of a PC    

Back to top Go down
 
Copy the last action of a PC
Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Badlands Action :: Talking about nwn :: Q&A-
Jump to: