TR_m7_NPC_Melur_Beloth
TR_Mainland.esm
Variables
5
Local Variables
TR_Map
control
controlQ
T_Local_NPC
NoLore
Source
1Begin TR_m7_NPC_Melur_Beloth
2
3;This is a modified version of TR_m4_NPC_PlantationOverseer for the quest TR_m7_Oth_EdalvelLetter
4
5
6; This short script is there to allow dialogue to be filtered on the TR_Map local variable,
7; allowing for regional topics such as "Morrowind Lore" or "Geographic Regions" to be
8; appropriate to the location the NPC is.
9
10short TR_Map
11short control
12short controlQ
13short T_Local_NPC
14short NoLore
15
16if ( GetCurrentAIPackage == 1 )
17 if ( GetAIPackageDone == 1 )
18 if ( controlq == 1 )
19 aiwander 0 5 0 52 20 10 10
20 sethello 30
21 set controlq to 2
22 forcegreeting
23 endif
24 endif
25endif
26
27if ( "TR_m7_S_Abeek-Jah"->OnDeath )
28 if ( controlq == 3 )
29 set controlq to 4
30 forcegreeting
31 elseif ( getjournalindex TR_m7_Oth_EdalvelLetter >= 50 )
32 if ( getjournalindex TR_m7_Oth_EdalvelLetter < 100 )
33 set controlQ to -1
34 journal tr_m7_oth_edalvelletter 160
35 endif
36 else
37 set controlQ to -1
38 endif
39endif
40
41if ( cellchanged )
42 if ( getjournalindex TR_m7_Oth_EdalvelLetter == 110 )
43 positionCell -3092 -355710 512 1380 "Edalvel Plantation" ; TR_m7_MARK_CB_Melur
44 aiwander 0 5 0 52 20 10 10
45 endif
46endif
47
48if ( ondeath )
49 if ( getjournalindex TR_m7_Oth_EdalvelLetter == 60 )
50 "TR_m7_S_Abeek-Jah"->disable
51 endif
52 if ( getjournalindex TR_m7_Oth_EdalvelLetter >= 10 )
53 if ( getjournalindex TR_m7_Oth_EdalvelLetter < 100 )
54 journal tr_m7_oth_edalvelletter 150
55 endif
56 endif
57 if ( controlQ == 3 )
58 "TR_m7_S_Abeek-Jah"->sethealth 67
59 endif
60endif
61
62if ( TR_Map == 7 )
63 return
64endif
65
66set TR_Map to 7
67
68End