Scripts

TR_m7_NPC_Shurlukh

TR_Mainland.esm
Variables 9
Local Variables
TR_Map
control
controlQ
NoLore
disableOnce
greetOnce
T_Local_NPC
T_Local_NoLore
OnPCHitMe
Source
1Begin TR_m7_NPC_Shurlukh 2; Script for the quest TR_m7_wil_Nymph 3 4short TR_Map 5short control 6short controlQ 7short NoLore 8short disableOnce 9short greetOnce 10short T_Local_NPC 11short T_Local_NoLore 12short OnPCHitMe 13 14; 1 == attacked after being told about Shurlukh 15; 2 == attacked earlier 16; set here or in Greeting 0 17; global TR_m7_NymphAttack 18 19if ( OnPCHitMe ) 20 if ( TR_m7_NymphAttack == 0 ) 21 if ( GetJournalIndex "TR_m7_wil_Nymph" < 30 ) 22 "TR_m7_Irmiel"->AddItem "T_De_NetchRogue_Cuirass_01" 1 23 "TR_m7_Irmiel"->AddItem "T_De_Cm_Pants_07" 1 24 "TR_m7_Irmiel"->AddItem "glass jinkblade" 1 25 endif 26 if ( GetJournalIndex "TR_m7_wil_Nymph" < 100 ) 27 setfight 100 28 set disableOnce to 2 29 enable 30 "TR_m7_Irmiel"->setfight 100 31 "TR_m7_Irmiel"->startcombat player 32 if ( GetJournalIndex "TR_m7_wil_Nymph" >= 15 ) 33 Journal "TR_m7_wil_Nymph" 110 34 set TR_m7_NymphAttack to 1 35 else 36 Journal "TR_m7_wil_Nymph" 120 37 set TR_m7_NymphAttack to 2 38 endif 39 endif 40 endif 41 startcombat player 42endif 43 44if ( disableOnce == 0 ) 45 disable 46 set disableOnce to 1 47endif 48 49if ( MenuMode == 1 ) 50 return 51endif 52 53if ( GetJournalIndex "TR_m7_wil_Nymph" >= 5 ) 54 if ( disableOnce == 1 ) 55 enable 56 set disableOnce to 2 57 endif 58endif 59 60if ( GetDisabled ) 61 return 62endif 63 64if ( TR_m7_NymphAttack == 0 ) 65 if ( GetDistance player <= 310 ) 66 if ( greetOnce == 0 ) 67 ForceGreeting 68 set greetOnce to 1 69 endif 70 endif 71endif 72 73; Trigger end of quest if both Irmiel and Shurlukh die 74if ( OnDeath ) 75 if ( GetJournalIndex "TR_m7_wil_Nymph" >= 5 ) 76 if ( GetDeadCount "TR_m7_Irmiel" > 0 ) 77 if ( TR_m7_NymphAttack == 1 ) 78 Journal "TR_m7_wil_Nymph" 200 79 else 80 Journal "TR_m7_wil_Nymph" 210 81 endif 82 endif 83 endif 84endif 85 86if ( TR_Map == 7 ) 87 return 88endif 89 90set TR_Map to 7 91 92End