2 # GemRB - Infinity Engine Emulator
3 # Copyright (C) 2003-2004 The GemRB Project
5 # This program is free software; you can redistribute it and/or
6 # modify it under the terms of the GNU General Public License
7 # as published by the Free Software Foundation; either version 2
8 # of the License, or (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software
17 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21 # GUIMG.py - scripts to control mage spells windows from the GUIMG winpack
23 ###################################################
26 from GUIDefines
import *
27 from ie_stats
import *
30 from ie_spells
import LS_MEMO
33 MageSpellInfoWindow
= None
35 MageSpellUnmemorizeWindow
= None
38 OldPortraitWindow
= None
39 OldOptionsWindow
= None
48 def OpenMageWindow ():
49 import GUICommonWindows
50 global MageWindow
, OptionsWindow
, PortraitWindow
51 global OldPortraitWindow
, OldOptionsWindow
53 if GUICommon
.CloseOtherWindow (OpenMageWindow
):
57 OptionsWindow
.Unload ()
59 PortraitWindow
.Unload ()
62 GemRB
.SetVar ("OtherWindow", -1)
63 GUICommon
.GameWindow
.SetVisible(WINDOW_VISIBLE
)
65 GUICommonWindows
.PortraitWindow
= OldPortraitWindow
66 OldPortraitWindow
= None
67 GUICommonWindows
.OptionsWindow
= OldOptionsWindow
68 OldOptionsWindow
= None
69 GUICommonWindows
.SetSelectionChangeHandler (None)
73 GUICommon
.GameWindow
.SetVisible(WINDOW_INVISIBLE
)
75 GemRB
.LoadWindowPack ("GUIMG", 640, 480)
77 #saving the original portrait window
78 OldOptionsWindow
= GUICommonWindows
.OptionsWindow
79 OptionsWindow
= GemRB
.LoadWindow (0)
80 GUICommonWindows
.MarkMenuButton (OptionsWindow
)
81 GUICommonWindows
.SetupMenuWindowControls (OptionsWindow
, 0, OpenMageWindow
)
82 OptionsWindow
.SetFrame ()
83 OldPortraitWindow
= GUICommonWindows
.PortraitWindow
85 PortraitWindow
= GUICommonWindows
.OpenPortraitWindow (0)
87 GUICommonWindows
.SetSelectionChangeHandler (SetupMageWindow
)
90 def SetupMageWindow ():
94 pc
= GemRB
.GameGetSelectedPCSingle ()
96 if (CommonTables
.ClassSkills
.GetValue (GemRB
.GetPlayerStat (pc
, IE_CLASS
), 8)==2):
104 MageWindow
= Window
= GemRB
.LoadWindow (8)
106 MageWindow
= Window
= GemRB
.LoadWindow (2)
107 GemRB
.SetVar ("OtherWindow", MageWindow
.ID
)
109 Button
= Window
.GetControl (1)
110 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, MagePrevLevelPress
)
112 Button
= Window
.GetControl (2)
113 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, MageNextLevelPress
)
116 Button
= Window
.GetControl (55)
117 Button
.SetState (IE_GUI_BUTTON_LOCKED
)
121 Button
= Window
.GetControl (56 + i
)
122 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, RefreshMageLevel
)
123 Button
.SetFlags (IE_GUI_BUTTON_RADIOBUTTON
, OP_OR
)
126 Button
= Window
.GetControl (56 + i
)
127 Button
.SetVarAssoc ("MageSpellLevel", i
)
129 # Setup memorized spells buttons
132 Button
= Window
.GetControl (3 + i
)
133 Button
.SetBorder (0,0,0,0,0,0,0,0,64,0,1)
134 Button
.SetSprites ("SPELFRAM",0,0,0,0,0)
135 Button
.SetFlags (IE_GUI_BUTTON_PICTURE
, OP_OR
)
136 Button
.SetState (IE_GUI_BUTTON_LOCKED
)
138 # Setup book spells buttons
140 Button
= Window
.GetControl (27 + i
)
141 Button
.SetFlags (IE_GUI_BUTTON_NO_IMAGE
, OP_OR
)
142 Button
.SetState (IE_GUI_BUTTON_LOCKED
)
145 OptionsWindow
.SetVisible (WINDOW_VISIBLE
)
146 #bringing the window front
147 Window
.SetVisible (WINDOW_FRONT
)
148 PortraitWindow
.SetVisible (WINDOW_VISIBLE
)
151 def UpdateMageWindow ():
152 global MageMemorizedSpellList
, MageKnownSpellList
154 MageMemorizedSpellList
= []
155 MageKnownSpellList
= []
158 pc
= GemRB
.GameGetSelectedPCSingle ()
159 type = IE_SPELL_TYPE_WIZARD
160 level
= MageSpellLevel
161 max_mem_cnt
= GemRB
.GetMemorizableSpellsCount (pc
, type, level
, 1)
163 Label
= Window
.GetControl (0x10000032)
164 GemRB
.SetToken("SPELLLEVEL", str(level
+1) )
165 Label
.SetText (10345)
167 Name
= GemRB
.GetPlayerName (pc
, 0)
168 Label
= Window
.GetControl (0x10000035)
171 known_cnt
= GemRB
.GetKnownSpellsCount (pc
, type, level
)
172 mem_cnt
= GemRB
.GetMemorizedSpellsCount (pc
, type, level
)
175 Button
= Window
.GetControl (3 + i
)
177 ms
= GemRB
.GetMemorizedSpell (pc
, type, level
, i
)
178 Button
.SetSpellIcon (ms
['SpellResRef'], 0)
179 Button
.SetFlags (IE_GUI_BUTTON_NO_IMAGE
, OP_NAND
)
180 Button
.SetFlags (IE_GUI_BUTTON_PICTURE
, OP_OR
)
182 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, OpenMageSpellUnmemorizeWindow
)
184 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, OnMageUnmemorizeSpell
)
185 Button
.SetEvent (IE_GUI_BUTTON_ON_RIGHT_PRESS
, OpenMageSpellInfoWindow
)
186 spell
= GemRB
.GetSpell (ms
['SpellResRef'])
187 Button
.SetTooltip (spell
['SpellName'])
188 MageMemorizedSpellList
.append (ms
['SpellResRef'])
189 Button
.SetVarAssoc ("SpellButton", i
)
190 Button
.EnableBorder (0, ms
['Flags'] == 0)
193 Button
.SetFlags (IE_GUI_BUTTON_NORMAL
, OP_SET
)
195 Button
.SetFlags (IE_GUI_BUTTON_NO_IMAGE
, OP_SET
)
196 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, None)
197 Button
.SetEvent (IE_GUI_BUTTON_ON_RIGHT_PRESS
, None)
198 Button
.SetTooltip ('')
199 Button
.EnableBorder (0, 0)
201 label
= Window
.GetControl (0x10000040)
203 # we give sorcerers all charges for all the spells, so some extra math is needed
204 label
.SetText (GemRB
.GetString(61256) + " " + str(mem_cnt
/known_cnt
) + "/" + str(max_mem_cnt
))
209 Button
= Window
.GetControl (27 + i
)
211 ks
= GemRB
.GetKnownSpell (pc
, type, level
, i
)
212 Button
.SetSpellIcon (ks
['SpellResRef'], 0)
213 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, OnMageMemorizeSpell
)
214 Button
.SetEvent (IE_GUI_BUTTON_ON_RIGHT_PRESS
, OpenMageSpellInfoWindow
)
215 spell
= GemRB
.GetSpell (ks
['SpellResRef'])
216 Button
.SetTooltip (spell
['SpellName'])
217 MageKnownSpellList
.append (ks
['SpellResRef'])
218 Button
.SetVarAssoc ("SpellButton", 100 + i
)
221 Button
.SetFlags (IE_GUI_BUTTON_PICTURE
, OP_NAND
)
222 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, None)
223 Button
.SetEvent (IE_GUI_BUTTON_ON_RIGHT_PRESS
, None)
224 Button
.SetTooltip ('')
225 Button
.EnableBorder (0, 0)
227 if (CommonTables
.ClassSkills
.GetValue (GemRB
.GetPlayerStat (pc
, IE_CLASS
), 2)=="*") or \
228 GemRB
.GetPlayerStat (pc
, IE_STATE_ID
) & STATE_DEAD
:
229 Window
.SetVisible (WINDOW_GRAYED
)
231 Window
.SetVisible (WINDOW_VISIBLE
)
234 def MagePrevLevelPress ():
235 global MageSpellLevel
237 if MageSpellLevel
> 0:
238 MageSpellLevel
= MageSpellLevel
- 1
242 def MageNextLevelPress ():
243 global MageSpellLevel
245 if MageSpellLevel
< 8:
246 MageSpellLevel
= MageSpellLevel
+ 1
250 def RefreshMageLevel ():
251 global MageSpellLevel
253 MageSpellLevel
= GemRB
.GetVar ("MageSpellLevel")
257 def OpenMageSpellInfoWindow ():
258 global MageSpellInfoWindow
260 if MageSpellInfoWindow
!= None:
261 if MageSpellInfoWindow
:
262 MageSpellInfoWindow
.Unload ()
263 MageSpellInfoWindow
= None
266 MageSpellInfoWindow
= Window
= GemRB
.LoadWindow (3)
269 Button
= Window
.GetControl (5)
270 Button
.SetText (15416)
271 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, OpenMageSpellInfoWindow
)
274 index
= GemRB
.GetVar ("SpellButton")
275 if GUICommon
.HasTOB():
276 Button
= Window
.GetControl (6)
278 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, None)
279 Button
.SetFlags (IE_GUI_BUTTON_NO_IMAGE
, OP_SET
)
281 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, OpenMageSpellRemoveWindow
)
282 Button
.SetText (63668)
284 ResRef
= MageMemorizedSpellList
[index
]
286 ResRef
= MageKnownSpellList
[index
- 100]
288 spell
= GemRB
.GetSpell (ResRef
)
290 Label
= Window
.GetControl (0x0fffffff)
291 Label
.SetText (spell
['SpellName'])
293 Button
= Window
.GetControl (2)
294 Button
.SetSpellIcon (ResRef
, 1)
296 Text
= Window
.GetControl (3)
297 Text
.SetText (spell
['SpellDesc'])
299 Window
.ShowModal (MODAL_SHADOW_GRAY
)
302 def OnMageMemorizeSpell ():
303 pc
= GemRB
.GameGetSelectedPCSingle ()
304 level
= MageSpellLevel
305 type = IE_SPELL_TYPE_WIZARD
307 index
= GemRB
.GetVar ("SpellButton") - 100
309 if GemRB
.MemorizeSpell (pc
, type, level
, index
):
313 def CloseMageSpellUnmemorizeWindow ():
314 global MageSpellUnmemorizeWindow
316 if MageSpellUnmemorizeWindow
:
317 MageSpellUnmemorizeWindow
.Unload ()
318 MageSpellUnmemorizeWindow
= None
321 def OpenMageSpellRemoveWindow ():
322 global MageSpellUnmemorizeWindow
324 MageSpellUnmemorizeWindow
= Window
= GemRB
.LoadWindow (101)
326 # "Are you sure you want to ....?"
327 TextArea
= Window
.GetControl (3)
328 TextArea
.SetText (63745)
331 Button
= Window
.GetControl (0)
332 Button
.SetText (17507)
333 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, OnMageRemoveSpell
)
334 Button
.SetFlags (IE_GUI_BUTTON_DEFAULT
, OP_OR
)
337 Button
= Window
.GetControl (1)
338 Button
.SetText (13727)
339 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, CloseMageSpellUnmemorizeWindow
)
340 Button
.SetFlags (IE_GUI_BUTTON_CANCEL
, OP_OR
)
342 Window
.ShowModal (MODAL_SHADOW_GRAY
)
345 def OpenMageSpellUnmemorizeWindow ():
346 global MageSpellUnmemorizeWindow
348 MageSpellUnmemorizeWindow
= Window
= GemRB
.LoadWindow (101)
350 # "Are you sure you want to ....?"
351 TextArea
= Window
.GetControl (3)
352 TextArea
.SetText (11824)
355 Button
= Window
.GetControl (0)
356 Button
.SetText (17507)
357 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, OnMageUnmemorizeSpell
)
358 Button
.SetFlags (IE_GUI_BUTTON_DEFAULT
, OP_OR
)
361 Button
= Window
.GetControl (1)
362 Button
.SetText (13727)
363 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, CloseMageSpellUnmemorizeWindow
)
364 Button
.SetFlags (IE_GUI_BUTTON_CANCEL
, OP_OR
)
366 Window
.ShowModal (MODAL_SHADOW_GRAY
)
369 def OnMageUnmemorizeSpell ():
370 if MageSpellUnmemorizeWindow
:
371 CloseMageSpellUnmemorizeWindow()
373 pc
= GemRB
.GameGetSelectedPCSingle ()
374 level
= MageSpellLevel
375 type = IE_SPELL_TYPE_WIZARD
377 index
= GemRB
.GetVar ("SpellButton")
379 if GemRB
.UnmemorizeSpell (pc
, type, level
, index
):
383 def OnMageRemoveSpell ():
384 CloseMageSpellUnmemorizeWindow()
385 OpenMageSpellInfoWindow()
387 pc
= GemRB
.GameGetSelectedPCSingle ()
388 level
= MageSpellLevel
389 type = IE_SPELL_TYPE_WIZARD
391 index
= GemRB
.GetVar ("SpellButton")-100
393 #remove spell from book
394 GemRB
.RemoveSpell (pc
, type, level
, index
)
398 def LoadCondition ():
399 global ContCond
, ContTarg
401 Table
= GemRB
.LoadTable ("contcond")
402 CondCount
= Table
.GetRowCount ()
403 ContCond
= [0] * CondCount
405 for i
in range (CondCount
):
406 #get the condition's name and description
407 tuple = (Table
.GetValue (i
, 0),Table
.GetValue (i
, 1) )
410 Table
= GemRB
.LoadTable ("conttarg")
411 TargCount
= Table
.GetRowCount ()
412 ContTarg
= [0] * TargCount
414 for i
in range (TargCount
):
415 #get the condition's name and description
416 tuple = (Table
.GetValue (i
, 0),Table
.GetValue (i
, 1) )
420 def OpenSequencerWindow ():
422 global ContingencyTextArea
, TypeButton
, OkButton
423 global Level
, MaxLevel
, Target
, Count
425 global ContCond
, ContTarg
426 global Spell1
, Spell2
, Spell3
, Source
435 #the target player (who receives the contingency or sequencer)
436 pc
= GemRB
.GetVar("P0")
438 MaxLevel
= GemRB
.GetVar("P1")
439 #target 0 - any, 1 - caster only, 2 - sequencer
441 p2
= GemRB
.GetVar("P2")
442 Source
= GemRB
.GetSpellCastOn(pc
)
444 print "Source: ", Source
450 GemRB
.LoadWindowPack ("GUIMG", 640, 480)
452 #saving the original portrait window
453 OtherWindow
= Window
= GemRB
.LoadWindow (6)
455 Title
= Window
.GetControl (0x0fffffff)
457 ContingencyTextArea
= Window
.GetControl (25)
461 Title
.SetText (55374)
462 ContingencyTextArea
.SetText (60420)
464 Title
.SetText (55375)
465 ContingencyTextArea
.SetText (55372)
468 Title
.SetText (11941)
470 Title
.SetText (55376)
471 ContingencyTextArea
.SetText (55373)
473 CondSelect
= Window
.GetControl (4)
474 CondLabel
= Window
.GetControl (0x10000000)
475 TargSelect
= Window
.GetControl (6)
476 TargLabel
= Window
.GetControl (0x10000001)
477 TypeButton
= Window
.GetControl (8)
479 #no cleric spells available
480 if (CommonTables
.ClassSkills
.GetValue (GemRB
.GetPlayerStat (pc
, IE_CLASS
), 0)=="*" and
481 CommonTables
.ClassSkills
.GetValue (GemRB
.GetPlayerStat (pc
, IE_CLASS
), 1)=="*"):
482 TypeButton
.SetState (IE_GUI_BUTTON_DISABLED
)
485 CondSelect
.SetPos (-1,-1)
486 CondLabel
.SetPos (-1,-1)
487 TargSelect
.SetPos (-1,-1)
488 TargLabel
.SetPos (-1,-1)
489 sb
= Window
.GetControl (5)
491 sb
= Window
.GetControl (7)
494 CondSelect
.SetFlags (IE_GUI_TEXTAREA_SELECTABLE
, OP_SET
)
495 CondSelect
.SetEvent (IE_GUI_TEXTAREA_ON_CHANGE
, ContingencyHelpCondition
)
496 CondSelect
.SetVarAssoc ("ContCond", 0)
497 for elem
in ContCond
:
498 CondSelect
.Append (elem
[0], -1)
500 TargSelect
.SetFlags (IE_GUI_TEXTAREA_SELECTABLE
, OP_SET
)
501 TargSelect
.SetEvent (IE_GUI_TEXTAREA_ON_CHANGE
, ContingencyHelpTarget
)
502 TargSelect
.SetVarAssoc ("ContTarg", 0)
503 for elem
in ContTarg
:
504 TargSelect
.Append (elem
[0], -1)
505 #check if target is only self
507 TargSelect
.SetVarAssoc ("ContTarg", 1)
510 GemRB
.SetVar ("SpellType", 0)
511 TypeButton
.SetVarAssoc ("SpellType", 1)
512 TypeButton
.SetFlags (IE_GUI_BUTTON_CHECKBOX
, OP_OR
)
513 TypeButton
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, ContTypePressed
)
515 Button
= Window
.GetControl (9)
516 Button
.SetEvent(IE_GUI_BUTTON_ON_PRESS
, LevelIncrease
)
517 Button
= Window
.GetControl (10)
518 Button
.SetEvent(IE_GUI_BUTTON_ON_PRESS
, LevelDecrease
)
520 OkButton
= Window
.GetControl (27)
521 OkButton
.SetText (11973)
522 OkButton
.SetFlags (IE_GUI_BUTTON_DEFAULT
, OP_OR
)
523 OkButton
.SetState (IE_GUI_BUTTON_DISABLED
)
525 CancelButton
= Window
.GetControl (29)
526 CancelButton
.SetText (13727)
527 CancelButton
.SetFlags (IE_GUI_BUTTON_CANCEL
, OP_OR
)
529 OkButton
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, ContingencyOk
)
530 CancelButton
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, ContingencyCancel
)
532 Window
.ShowModal (MODAL_SHADOW_GRAY
)
535 def UpdateSpellList ():
539 Type
= IE_SPELL_TYPE_PRIEST
541 Type
= IE_SPELL_TYPE_WIZARD
543 Label
= Window
.GetControl (0x1000001d)
544 Label
.SetText (GemRB
.GetString(12137)+str(Level
) )
546 BuildSpellList(pc
, Type
, Level
-1)
548 names
= SpellList
.keys()
553 for i
in range(11,20):
554 Button
= Window
.GetControl (i
)
555 Button
.SetFont ("NUMBER")
556 Button
.SetFlags (IE_FONT_ALIGN_RIGHT|IE_FONT_ALIGN_BOTTOM
,OP_OR
)
558 Button
.SetSpellIcon (names
[j
], 1)
559 Button
.SetText( str(SpellList
[names
[j
]]) )
560 Button
.SetVarAssoc("Index", j
)
561 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, ContingencyHelpSpell
)
562 Button
.SetState (IE_GUI_BUTTON_ENABLED
)
564 Button
.SetSpellIcon("")
566 Button
.SetState (IE_GUI_BUTTON_DISABLED
)
569 Button
= Window
.GetControl (22)
570 Button
.SetSpellIcon(Spell1
, 1)
571 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, DeleteSpell1
)
572 Button
= Window
.GetControl (23)
573 Button
.SetSpellIcon(Spell2
, 1)
574 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, DeleteSpell2
)
575 Button
= Window
.GetControl (24)
576 Button
.SetSpellIcon(Spell3
, 1)
577 Button
.SetEvent (IE_GUI_BUTTON_ON_PRESS
, DeleteSpell3
)
580 OkButton
.SetState (IE_GUI_BUTTON_DISABLED
)
582 OkButton
.SetState (IE_GUI_BUTTON_ENABLED
)
585 def ContTypePressed ():
588 Label
= OtherWindow
.GetControl (0x10000002)
589 SpellType
= GemRB
.GetVar ("SpellType")
592 Label
.SetText (54352)
593 TypeButton
.SetText (18039)
595 Label
.SetText (21836)
596 TypeButton
.SetText (7204)
600 def ContingencyOk ():
605 GemRB
.ApplyEffect (pc
, "Sequencer:Store", 0, 0, Spell1
, Spell2
, Spell3
, Source
)
607 GemRB
.ApplyEffect (pc
, "CastSpellOnCondition", 0, GemRB
.GetVar ("ContCond"), Spell1
, Spell2
, Spell3
, Source
)
609 GemRB
.LearnSpell (pc
, Source
+"d", LS_MEMO
)
613 def ContingencyCancel ():
616 GemRB
.SetPlayerStat (pc
, IE_IDENTIFYMODE
, 0)
620 def ContingencyHelpSpell ():
621 global Spell1
, Spell2
, Spell3
623 names
= SpellList
.keys()
625 i
= GemRB
.GetVar("Index")
628 if Spell1
=="" and Count
>0:
630 elif Spell2
=="" and Count
>1:
632 elif Spell3
=="" and Count
>2:
635 spl
= GemRB
.GetSpell(spell
)
636 ContingencyTextArea
.SetText (spl
["SpellDesc"])
641 global Spell1
, Spell2
, Spell3
646 ContingencyTextArea
.SetText("")
651 global Spell2
, Spell3
655 ContingencyTextArea
.SetText("")
663 ContingencyTextArea
.SetText("")
667 def ContingencyHelpCondition ():
668 i
= GemRB
.GetVar ("ContCond")
669 ContingencyTextArea
.SetText (ContCond
[i
][1])
672 def ContingencyHelpTarget ():
673 i
= GemRB
.GetVar ("ContTarg")
674 ContingencyTextArea
.SetText (ContTarg
[i
][1])
677 def LoadExclusions():
680 ExclusionTable
= GemRB
.LoadTable ("contingx")
681 Columns
= ExclusionTable
.GetColumnCount ()
682 Rows
= ExclusionTable
.GetRowCount ()
684 for i
in range (Columns
):
685 Exclusions
.append ([])
686 for j
in range (Rows
):
687 spell
= ExclusionTable
.GetValue (j
,i
,0)
690 Exclusions
[i
].append (spell
.lower())
694 #TODO: build a correct list for sorcerers too!
695 def BuildSpellList (pc
, type, level
):
702 dummy
= [Spell1
,Spell2
,Spell3
]
703 mem_cnt
= GemRB
.GetMemorizedSpellsCount (pc
, type, level
)
705 for i
in range(mem_cnt
):
706 ms
= GemRB
.GetMemorizedSpell (pc
, type, level
, i
)
708 spell
= ms
["SpellResRef"]
709 if spell
in Exclusions
[level
]:
714 if not (spell
in SpellList
):
717 SpellList
[spell
] = SpellList
[spell
]+1
736 ###################################################
737 # End of file GUIMG.py