Why does everyone hate my actor?

Post » Wed Jun 20, 2012 1:56 pm

I have a spell that places actors near me and then uses StartCombat() to make them attack the appropriate targets. I put the actor in the Player Faction and in the Player Follower Faction.

However, it seems that everyone hates my new actors, and will run to attack them the moment they appear. This includes my own summons, reanimated minions, and followers! Why is this, when the only faction that the actor is in are those two factions?
User avatar
stacy hamilton
 
Posts: 3354
Joined: Fri Aug 25, 2006 10:03 am

Post » Wed Jun 20, 2012 8:55 pm

Most people are less than well disposed to people who attack them.

And many NPCs have things like "Helps allies and friends" in their AI behavior..so if your NPC attacks an NPC with lots of allies around, there you go.
User avatar
RObert loVes MOmmy
 
Posts: 3432
Joined: Fri Dec 08, 2006 10:12 am

Post » Wed Jun 20, 2012 10:47 pm

Most people are less than well disposed to people who attack them.

And many NPCs have things like "Helps allies and friends" in their AI behavior..so if your NPC attacks an NPC with lots of allies around, there you go.

That makes perfect sense. But why then, do these new actors that I create with PlaceAtMe() show up as hostile red dots on my compass, and get red health bars when I look at them? And why are my darn followers and summons attacking it?

When I tested this, I attack a guard in a city. Of course, as usual, they get all pissy and 3-4 guards show up and wail on me. However, all the citizens, which I have not attacked yet, go running in all directions, and are NOT hostile to me yet! Then, I cast the spell, and actors get created and rush out to engage the guards that are attacking me while I channel the spell. All the sudden, the citizens decide they want to take up arms and attack them!

They didn't mind when I cleaved a guard in two with my axe, but as soon as I make a skeleton, they get all pissy and want to murder it on sight. And the moment the skeleton goes away, the citizens (and my followers) put away their weapons and return to their lives! Well, not my followers and summons, they keep their weapons out and charge at the next guard to attack me.


How do I get these guys to be on my team? They aren't attacking me because I am using frequent updates to force them to attack a specific target, but if I didn't do that, I am almost positive they would attack me given the chance despite being in my faction!
User avatar
Danii Brown
 
Posts: 3337
Joined: Tue Aug 22, 2006 7:13 am

Post » Wed Jun 20, 2012 4:09 pm

Are you are spawning the default skeletons that are already in the game? If so, i guess things have been set up faction-wise for everybody to consider them enemies. Perhaps duplicating the skeleton race, giving them a unique id, delete any factions except the player follower faction, and then spawning these in your spell might work???

- Hypno
User avatar
Laura Richards
 
Posts: 3468
Joined: Mon Aug 28, 2006 4:42 am

Post » Wed Jun 20, 2012 2:59 pm

Is it a custom NPC you made? You have to change the AI data on the Actor dialog window to be less aggressive, essentially. And you shouldn't need to use StartCombat() if they're in the PlayerFollowerFaction with the appropriate rank set, if you are being attacked, they will enter combat on their own due to the way the default master package works.
User avatar
Maddy Paul
 
Posts: 3430
Joined: Wed Feb 14, 2007 4:20 pm

Post » Wed Jun 20, 2012 4:25 pm

Are you are spawning the default skeletons that are already in the game? If so, i guess things have been set up faction-wise for everybody to consider them enemies. Perhaps duplicating the skeleton race, giving them a unique id, delete any factions except the player follower faction, and then spawning these in your spell might work???

- Hypno

As I said, It is a duplicated and modified version of the necro skeleton race. I already deleted all factions aside from player follower faction.

I have even gone so far as to give them a new race (referenced in the actor form) that does NOT have the undead and creature keywords. Could it have to do with them being very agressive as opposed to just agressive? I found that when I use just aggressive, the idiots stop attacking enemies that fall to their knees (right before they die). Which is annoying, I want the skeletons to go balls to the wall and chop stuff up until it has zero health.

The reason I use startcombat and frequent checks with getcombattarget() during onupdate() events is to force the skeletons to only attack a specific target. I want each skeleton that spawns to attack one target, I don't want them getting distracted and attacking other targets or ganging up on people. The spell spawns one skeleton per enemy, so I use the script to make sure that each skeleton is doing the job it was spawned to do.

I don't want them to simply respond to me being hit. The spell is a concentration spell and drains magicka pretty quickly, and it is meant to be a powerful spell where you create skeletons that actively run down enemies in the area that you are in combat with and finish them off, filling your soul gems, not just protect you if you get hit.
User avatar
Nathan Risch
 
Posts: 3313
Joined: Sun Aug 05, 2007 10:15 pm

Post » Wed Jun 20, 2012 2:19 pm

Could it have to do with them being very agressive as opposed to just agressive?

Yes.
User avatar
brenden casey
 
Posts: 3400
Joined: Mon Sep 17, 2007 9:58 pm

Post » Thu Jun 21, 2012 12:12 am

Yes.

No kidding... Sometimes I hate the way this game was made so much. Well, that did the trick. So basically making a creature very aggressive is more like, making it very hated.

Anyways, thanks, that solved the issue. A shorter RegisterForSingleUpdate() seems to be forcing the skeletons to continue attacking when enemies go into the kneeling position pretty seamlessly.

Problem solved.
User avatar
Shiarra Curtis
 
Posts: 3393
Joined: Thu Jan 04, 2007 3:22 pm


Return to V - Skyrim