TR_m7_MT_WritTuresa
TR_Mainland.esm
Variables
8
Local Variables
CL1
CL2
TR_map
control
controlQ
nolore
T_Local_NPC
OnPCHitMe
Source
1Begin TR_m7_MT_WritTuresa
2
3; control states
4; 0 = alive
5; 1 = dead
6; Used by TR_m7_NPC_Arvena_Veldyn to determine if she should try to heal Turesa
7
8; controlQ states
9; 0 = initial state
10; 1 = has either been attacked by player, or initiated dialogue
11; will move TR_m7_Arvena Veldyn into her tent
12; 2 = moving has been done
13
14short CL1
15short CL2
16short TR_map
17short control
18short controlQ
19short nolore
20short T_Local_NPC
21short OnPCHitMe
22
23set TR_map to 7
24
25if ( controlQ == 0 )
26 if ( OnPCHitMe )
27 set controlQ to 1
28 set OnPCHitMe to 0
29 endif
30endif
31
32if ( controlQ == 1 )
33 if ( GetDeadCount "TR_m7_Arvena Veldyn" == 0 )
34 "TR_m7_Arvena Veldyn"->PositionCell 4047 3717 15557 0 "Turesa Veldyn's Tent" ; TR_m7_MARK_Arvena Veldyn
35 "TR_m7_Arvena Veldyn"->SetFight 100
36 "TR_m7_Arvena Veldyn"->StartCombat Player
37 endif
38 set controlQ to 2
39endif
40
41if ( MenuMode == 1 )
42 return
43endif
44
45if ( CellChanged == 1 )
46 set CL1 to GetPCCrimeLevel
47endif
48
49if ( OnDeath == 1 )
50 ; when we are killed...
51
52 if ( GetJournalIndex TR_m7_MT_Turesa > 0 )
53 ; ... and if the player has a writ for us...
54
55 set CL2 to GetPCCrimeLevel
56 if ( CL2 > CL1 )
57 ; ... append a journal entry if the execution is seen ...
58 Player->Journal TR_m7_MT_Turesa 80
59 else
60 ; ... append a journal entry if the execution is NOT seen ...
61 Player->Journal TR_m7_MT_Turesa 90
62 endif
63 endif
64 set control to 1
65endif
66
67End