Making npcs hostile to the player

Post » Wed Jun 20, 2012 10:50 am

Hi!

I am just trying to make a npc and his friends turn hostile to the player at the end of a conversation.
I made it the same way than when the thalmor patrol could turn hostile if you question them too much, I created an hostile to the player faction and at the end of the dialogue I do a akSpeaker.AddToFaction(enemyfaction).

Problem is the npc attacks me but not his friends, they just stare at the fight...

I am obviously missing something, but what?
User avatar
Karen anwyn Green
 
Posts: 3448
Joined: Thu Jun 15, 2006 4:26 pm

Post » Wed Jun 20, 2012 2:24 pm

You might need to take a look at the others' AI data. Check what their aggressiveness is, whether or not they help allies/friends, etc. If nothing seems out of place, you could try using http://www.creationkit.com/SetEnemy_-_Faction instead.
User avatar
[ becca ]
 
Posts: 3514
Joined: Wed Jun 21, 2006 12:59 pm

Post » Wed Jun 20, 2012 5:11 am

Both (Thalmors characters and mine) are set to help friends and allies...thalmor is very aggressive and my faction (vigilants) is aggressive, I don't think that's the problem and I would like to avoid to modify vanilla factions for compatibility.
I don't really want to use Setenemy because I only want the nearby npcs to go hostile...it works for the thalmor, it should work here :(
User avatar
Amber Ably
 
Posts: 3372
Joined: Wed Aug 29, 2007 4:39 pm

Post » Wed Jun 20, 2012 8:18 am

If nothing works, then I guess you're just going to have to use StartCombat(Game.GetPlayer()) on all three of them.
User avatar
Lyd
 
Posts: 3335
Joined: Sat Aug 26, 2006 2:56 pm

Post » Wed Jun 20, 2012 10:17 am

But I don't necessarily know where there are or how many there are, except in their bastion...
User avatar
Lisa
 
Posts: 3473
Joined: Thu Jul 13, 2006 3:57 am

Post » Wed Jun 20, 2012 12:52 pm

Sorry, I thought you were using quest aliases like in WERoad03. Hmm... did you check to see whether or not your 3 actors are friends and allies? Maybe that's why they don't help each other. I really can't think of why else they wouldn't.

You say that you don't know where or how many there are. So just how exactly is this dialogue supposed to happen? Do you get this dialogue from every single actor in the bastion, and you want everyone in the same room as the current speaker to attack the player?
User avatar
Lloyd Muldowney
 
Posts: 3497
Joined: Wed May 23, 2007 2:08 pm

Post » Wed Jun 20, 2012 2:49 am

No, like in WEThalmorDialogue.

Well, there are all in the VigilantsOfStendarrFaction which is allied with itself, so they should all be allies. And if I directly attack one myself they are helping eachother.

In fact you can see the dialogue for yourself, I am trying to reactivate some unused dialogue of the vigilant and expand it a bit, look at the DialogueGenericVigilantsofStendarr quest, in the Dialogue view there is a part where vigilants try to take your daedric artifacts. I am just trying to make the speaker and nearby vigilants attack the player if you refuse.
User avatar
Tha King o Geekz
 
Posts: 3556
Joined: Mon May 07, 2007 9:14 pm

Post » Wed Jun 20, 2012 5:44 am

Hmm... that is weird how they don't help each other until you attack one of them. I can't figure it out either.

Since you say they help each other if you attack them first, try using akSpeaker.SendAssaultAlarm().
User avatar
celebrity
 
Posts: 3522
Joined: Mon Jul 02, 2007 12:53 pm

Post » Wed Jun 20, 2012 7:43 am

Well, it seems to work perfectly, thanks a lot!

In fact this is an even better solution since I don't need to create a fake faction...it makes me wonder why the thalmor quest doesn't use the same method!
User avatar
Juan Cerda
 
Posts: 3426
Joined: Thu Jul 12, 2007 8:49 pm

Post » Wed Jun 20, 2012 3:31 am

Well, send assault alarm makes the game think you just attacked the other person. So it's got side effects like guards trying to attack or arrest you if they happen to be there. The method with the factions is a lot cleaner.
User avatar
Rex Help
 
Posts: 3380
Joined: Mon Jun 18, 2007 6:52 pm

Post » Wed Jun 20, 2012 10:32 am

Oh...well yes, it can be a problem...
So back to mess with factions...tried to put all the npcs into a frenzied agression level, added alliance between standard and fake vigilant factions (there are none with the thalmor ones) but still no luck :(

I wonder why I always end to pass hours to do the simpliest thing in the ck and it still doesn't work! :stare:
User avatar
N3T4
 
Posts: 3428
Joined: Wed Aug 08, 2007 8:36 pm


Return to V - Skyrim