TR_m2_q_30_potionchest
TR_Mainland.esm
Variables
2
Local Variables
currentDay
localdaysPassed
Source
1Begin TR_m2_q_30_potionchest
2
3; script on Container TR_m2_MG_Aka_paralys.
4; This is the container that gets filled up with paralysis resistance potions each day since the quest TR_m2_MG_Polodie1
5; is finished.
6
7short currentDay
8short localdaysPassed
9
10if ( getJournalIndex TR_m2_MG_Polodie1 < 140 )
11 return
12endif
13
14if ( currentDay == Day )
15 return
16endif
17
18set localdaysPassed to ( Day - currentDay ) ; yes, this breaks if exactly one month has passed.
19
20set currentDay to Day
21
22if ( localdaysPassed > 4 )
23 set localdaysPassed to 4
24elseif ( localdaysPassed < 0 )
25 set localdaysPassed to 3
26endif
27
28while ( localdaysPassed > 0 )
29 if ( getItemCount T_Com_Potion_ResistParalysis_E < 8 )
30 additem T_Com_Potion_ResistParalysis_E 2
31 endif
32 if ( getItemCount T_Com_Potion_ResistParalysis_S < 12 )
33 additem T_Com_Potion_ResistParalysis_S 3
34 endif
35 if ( getItemCount T_Com_Potion_ResistParalysis_B < 8 )
36 additem T_Com_Potion_ResistParalysis_B 2
37 endif
38 if ( getItemCount T_Com_Potion_ResistParalysis_C < 8 )
39 additem T_Com_Potion_ResistParalysis_C 2
40 endif
41 if ( getItemCount T_Com_Potion_ResistParalysis_Q < 12 )
42 additem T_Com_Potion_ResistParalysis_Q 3
43 endif
44 set localdaysPassed to ( localdaysPassed - 1 )
45endwhile
46
47End