TR_m4_VA_vampvictim_scr
TR_Mainland.esm
Variables
5
Local Variables
nolore
moveonce
killonce
T_Local_NPC
TR_Map
Source
1begin TR_m4_VA_vampvictim_scr
2
3short nolore
4short moveonce
5short killonce
6short T_Local_NPC
7short TR_Map
8
9if ( MenuMode )
10 return
11endif
12
13if ( TR_Map != 4 )
14 set TR_Map to 4
15endif
16
17if ( CellChanged )
18 if ( killonce == 0 )
19 if ( GetJournalIndex, "TR_m4_VA_IronandBlood" >= 30 )
20 if ( GetJournalIndex TR_m4_VA_Ironandblood < 50 )
21 sethealth 0
22 set killonce to 1
23 PositionCell, 1991, 1910, 24565, 0, "Anbarsud, Shrine"
24 endif
25 endif
26 endif
27endif
28
29if ( GetPCCell, "Anbarsud, Shrine" == 1 )
30 set TR_m4_vampvictim_incell to 1
31 if ( TR_m4_orlukhgate02_glb == 1 )
32 if ( GetDistance, Player > 1000 )
33 if ( moveonce == 0 )
34 PositionCell, 1991, 1910, 24565, 0, "Anbarsud, Shrine"
35 AIWander, 0, 0, 0
36 endif
37 endif
38 set moveonce to 1
39 endif
40else
41 set TR_m4_vampvictim_incell to 0
42endif
43
44if ( GetPCCell, "Ald Virak" == 1 )
45 if ( GetCurrentAIPackage == 3 )
46 if ( TR_m4_VA_resetscout == 0 )
47 set TR_m4_VA_resetscout to 1
48 ForceGreeting
49 endif
50 endif
51endif
52
53if ( GetJournalIndex TR_m4_VA_Ironandblood >= 200 )
54 if ( CellChanged )
55 AIWander 0 0 0
56 disable
57 elseif ( GetJournalIndex TR_m4_VA_Ironandblood >= 220 ) ;cellchanged sometimes doesn't work on recalling
58 AIWander 0 0 0
59 disable
60 endif
61endif
62
63if ( OnDeath )
64 if ( GetJournalIndex TR_m4_VA_Ironandblood >= 30 )
65 Journal TR_m4_VA_Ironandblood 50
66 TR_m4_Budak->Stopcombat
67 endif
68endif
69
70end