TR_m7_NPC_BrokeHisOath
TR_Mainland.esm
Variables
6
Local Variables
TR_Map
control
controlQ
T_Local_NPC
NoLore
T_Local_NoLore
Source
1Begin TR_m7_NPC_BrokeHisOath
2; This short script is there to allow dialogue to be filtered on the TR_Map local variable,
3; allowing for regional topics such as "Morrowind Lore" or "Geographic Regions" to be
4; appropriate to the location the NPC is.
5
6short TR_Map
7short control
8short controlQ
9short T_Local_NPC
10short NoLore
11short T_Local_NoLore
12
13if ( OnDeath )
14 Set control to 1
15 Set TR_m7_Ns_ArenaDuelActive to 0
16 Set TR_m7_Ns_ArenaDuelManager.duelWon to 1
17 Journal TR_m7_HR_AldIuval_q5 90
18endif
19
20if ( controlQ == 0 )
21 set controlQ to 1
22 Disable
23 return
24endif
25
26if ( CellChanged )
27 if ( GetDisabled == 0 )
28 if ( GetJournalIndex TR_m7_HR_AldIuval_q5 < 80 )
29 Disable
30 elseif ( GetJournalIndex TR_m7_HR_AldIuval_q5 >= 90 )
31 Disable
32 endif
33 elseif ( GetJournalIndex TR_m7_HR_AldIuval_q5 == 80 )
34 Enable
35 endif
36endif
37
38if ( GetJournalIndex TR_m7_HR_AldIuval_q5 == 80 )
39 if ( GetHealthGetRatio < 0.15 )
40 if ( control == 0 )
41 ForceGreeting
42 endif
43 elseif ( player->GetHealthGetRatio < 0.15 )
44 if ( control == 0 )
45 ForceGreeting
46 endif
47 endif
48endif
49
50if ( TR_Map == 7 )
51 return
52endif
53
54set TR_Map to 7
55
56End