TR_m3_RDDorogGroDurin-Script
TR_Mainland.esm
Variables
9
Local Variables
TR_Map
control
controlQ
NoLore
T_Local_NPC
T_Local_NoLore
DoOnce
ProtectOnce
Newonce
Source
1Begin TR_m3_RDDorogGroDurin-Script
2
3Short TR_Map
4short control
5short controlQ
6short NoLore
7short T_Local_NPC
8short T_Local_NoLore
9Short DoOnce
10Short ProtectOnce
11Short Newonce
12
13If ( cellchanged == 1 ) ;disables the npcs on cellchange in the one scenario where you complete the quest in their vicinity.
14 If ( GetJournalIndex "TR_m4_And_Routinedelivery" == 100 )
15 if ( getdisabled == 0 )
16 disable
17 Endif
18 Endif
19Endif
20
21If ( Control == 0 ) ;Should disable the npc before the quest starts.
22 If ( GetJournalIndex "TR_m4_And_Routinedelivery" < 30 )
23 Disable
24 set control to 1
25 Endif
26Endif
27
28If ( newonce == 0 ) ;changes control variable
29 If ( GetJournalIndex "TR_m4_And_Routinedelivery" >= 30 )
30 enable
31 set control to 2
32 set newonce to 1
33 Endif
34Endif
35
36If ( getdisabled == 0 ) ;should disable the npc after the quest is over. unless they're dead.
37 If ( GetJournalIndex "TR_m4_And_Routinedelivery" == 100 )
38 Return
39 Elseif ( GetJournalIndex "TR_m4_And_Routinedelivery" >= 75 )
40 If ( gethealth != 0 )
41 Disable
42 Endif
43 Endif
44Endif
45
46If ( ProtectOnce == 0 ) ;should make it so this npc protects other members of Hles Vervul's gang
47 If ( "TR_m3_Hles_Vervul"->GetAttacked == 1 )
48 StartCombat player
49 SetFight 90
50 SetDisposition 0
51 Set ProtectOnce to 1
52 elseif ("TR_m3_Sulada_Syrivis"->GetAttacked == 1 )
53 StartCombat player
54 Setfight 90
55 SetDisposition 0
56 Set ProtectOnce to 1
57 endif
58endif
59
60If ( DoOnce != 1 ) ;updates global variable TR_m3_q_RD_HlesGangDead when the npc is killed.
61 If ( GetJournalIndex "TR_m4_And_Routinedelivery" < 100 )
62 If ( Ondeath == 1 )
63 Set TR_m3_q_RD_HlesGangDead to ( TR_m3_q_RD_HlesGangDead + 1 )
64 Set DoOnce to 1
65 Endif
66 Endif
67Endif
68
69If ( TR_m3_q_RD_HlesGangDead == 3 )
70 Journal "TR_m4_And_Routinedelivery" 66
71 Set TR_m3_q_RD_HlesGangDead to 4
72Endif
73
74if ( TR_Map == 3 )
75 return
76endif
77
78set TR_Map to 3
79
80end