Jump to content

RemoveFromFaction: does it actually work?


Recommended Posts

Posted

So... I have this little scene in mind where the PC gets to kill an npc who raped her with impunity. Because rape is bad, m'kay?

 

Starting the combat is easy enough with a "startcombat player" in a dialog result script. But other npcs around me take the rapist's side, due to "help friends & allies" AI, I'm guessing. So let's twiddle with the factions, I thought, and removed the rapist from the relevant factions with removefromfaction, and just to make sure, added him to a brand new faction that is set as enemy to all factions around, like this:

 


RemoveFromFaction GoodspringsFaction
RemoveFromFaction GoodspringsMilitiaFaction
AddToFaction PCCanKillMeFaction 1
SetDisposition player 0
startcombat player
[/Code]

(all of that in an end result script, so the reference is implied)

 

And guess what: it doesn't work. It also doesn't work if I make the reference explicit. Browsed the Beth & Nexus forums for ideas, but no help as far as I could see.

Some of the npc's picking the wrong side in this little fight are added by AWOP, but their faction is plain old GoodspringsFaction so it shouldn't matter.

What am I doing wrong? Probably something simple ;)

Posted

You might need to wait a few frames for it to take effect.. there's almost no telling which functions in the engine take effect right away and which ones are queued.

 

A test script that does something like.. add to faction, check faction membership, remove from faction, test faction membership -- in one frame -- would answer that question.

Posted

You might need to wait a few frames for it to take effect.. there's almost no telling which functions in the engine take effect right away and which ones are queued.

 

A test script that does something like.. add to faction' date=' check faction membership, remove from faction, test faction membership -- in one frame -- would answer that question.

[/quote']

 

Argh, of course. No immediate effect if checked in the same frame, so I'll probably have to add a spell script or something. Thanks!

Posted

So... I have this little scene in mind where the PC gets to kill an npc who raped her with impunity. Because rape is bad' date=' m'kay?

 

Starting the combat is easy enough with a "startcombat player" in a dialog result script. But other npcs around me take the rapist's side, due to "help friends & allies" AI, I'm guessing. So let's twiddle with the factions, I thought, and removed the rapist from the relevant factions with removefromfaction, and just to make sure, added him to a brand new faction that is set as enemy to all factions around, like this:

 


RemoveFromFaction GoodspringsFaction
RemoveFromFaction GoodspringsMilitiaFaction
AddToFaction PCCanKillMeFaction 1
SetDisposition player 0
startcombat player
[/Code]

(all of that in an end result script, so the reference is implied)

 

And guess what: it doesn't work. It also doesn't work if I make the reference explicit. Browsed the Beth & Nexus forums for ideas, but no help as far as I could see.

Some of the npc's picking the wrong side in this little fight are added by AWOP, but their faction is plain old GoodspringsFaction so it shouldn't matter.

What am I doing wrong? Probably something simple ;)

[/quote']

 

Study the script for cass, I only briefly looked it over but I believe she is removed from all factions.

Posted

Study the script for cass' date=' I only briefly looked it over but I believe she is removed from all factions.

[/quote']

 

Thanks, but I managed to muddle through regardless. Despite a few inexplicable geck crashes along the way :-/

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

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