TR_m3_SummonZymelKaazGem
TR_Mainland.esm
Variables
3
Local Variables
state
DoOnce
timer
Source
1begin TR_m3_SummonZymelKaazGem
2
3; This is the script used to summon the unique storm atronach from the quest Ambassador Trouble
4
5short state
6short DoOnce
7float timer
8
9if ( state == 0 )
10 if ( player->getspelleffects "TR_m3_summon Zymel Kaaz" )
11 if ( player->GetItemCount "TR_m3_ZymelKaazSoulGem" < 1 )
12 if ( DoOnce == 0 )
13 MessageBox "You do not have the soulgem of Zymel Kaaz."
14 set DoOnce to 1
15 Return
16 endif
17 elseif ( player->GetItemCount "TR_m3_ZymelKaazSoulGem" >= 1 )
18 if ( player->GetMagicka < 100 )
19 if ( DoOnce == 0 )
20 MessageBox "The soulgem requires more magicka to summon Zymel Kaaz."
21 set DoOnce to 1
22 Return
23 endif
24 else
25 player->modcurrentmagicka -100
26 placeatpc "TR_m3_cr_HTAtronach" 1, 100, 0
27 set state to 1
28 endif
29 endif
30 else
31 set DoOnce to 0
32 endif
33
34
35elseif ( State == 1 )
36 set timer to ( timer + getsecondspassed ) ;the timer will prevent the player
37 if ( timer > 95 ) ;from being able to create several instances of the creature at the same time.
38 set state to 0
39 set timer to 0
40 endif
41Endif
42
43end