tylerjk Posted April 25, 2005 Share Posted April 25, 2005 How do I write a script that will make a npc fight me? Like if I wanted to talk to him then say I want to kill you or say join my party or something. I just need to see what that script would look like. Link to comment Share on other sites More sharing options...
stoffe Posted April 25, 2005 Share Posted April 25, 2005 Originally posted by tylerjk How do I write a script that will make a npc fight me? Like if I wanted to talk to him then say I want to kill you or say join my party or something. I just need to see what that script would look like. If you want the one you speak to to go hostile and attack you, a script like this on the ending node of that conversation branch would probably work: #include "k_inc_generic" void main() { object oPC = GetPCSpeaker(); ChangeToStandardFaction(OBJECT_SELF, STANDARD_FACTION_HOSTILE_1); DelayCommand(0.5, GN_DetermineCombatRound(oPC)); } EDIT: Or, if you are feeling efficient you could use the script "a_atkonend" that comes with the game, and apparently does pretty much the same thing. Figured there would be a generic script doing this already. Link to comment Share on other sites More sharing options...
tylerjk Posted April 25, 2005 Author Share Posted April 25, 2005 hmm, yeah I will try this. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.