TR_m4_AA_Ganahiru_Script
TR_Mainland.esm
Variables
2
Local Variables
aggressive
greetOnce
Source
1begin TR_m4_AA_Ganahiru_Script
2
3;script for Ga'Nahiru, the Great Kagouti of the Armun Ashlands Region
4
5short aggressive
6short greetOnce
7
8; Ga'Nahiru is passive by default and will not attack unless the player gets pretty close
9if ( aggressive == 0 )
10 if ( GetPCSneaking )
11 if ( GetDistance player < 400 )
12 SetFight 90
13 set aggressive to 1
14 endif
15 elseif ( GetDistance player < 800 )
16 SetFight 90
17 set aggressive to 1
18 endif
19endif
20
21; this handles quest journal entires
22if ( GetJournalIndex "TR_m4_wil_GaNahiru" == 10 )
23 if ( greetOnce == 0 )
24 if ( GetDistance "TR_m4_Shara-Ahhe" < 2300 )
25 set greetOnce to 1
26 "TR_m4_Shara-Ahhe"->ForceGreeting
27 endif
28 endif
29 if ( OnDeath )
30 "TR_m4_Shara-Ahhe"->AIWander 64 0 20 0 10 0 0
31 "TR_m4_Shara-Ahhe"->ClearForceSneak
32 "TR_m4_Hansi"->AiWander 64 0 20 0 10 0 0
33 "TR_m4_Hansi"->ClearForceSneak
34 if ( GetDeadCount "TR_m4_Shara-Ahhe" == 0 )
35 Journal "TR_m4_wil_GaNahiru" 50
36 elseif ( GetDeadCount "TR_m4_Hansi" == 0 )
37 Journal "TR_m4_wil_GaNahiru" 75
38 else
39 Journal "TR_m4_wil_GaNahiru" 100
40 endif
41 endif
42endif
43
44end