magik.qsrc 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. # magik
  2. act 'Physical attacks':gt'boxing'
  3. if spellMana['fog'] = 0:
  4. gs 'spellList'
  5. end
  6. $SpellListStr = "
  7. <center>
  8. <h1>Choose a Spell to cast.</h1>
  9. <br>
  10. <table CELLPADDING = '5'>
  11. <tr>
  12. <th align='left'>Spell</th>
  13. <th align='left'>Mana</th>
  14. <th align='left'>Description</th>
  15. </tr>"
  16. i = 0
  17. numSpellsKnown = 0
  18. :CombatSpellLoop
  19. $ThisSpellName = $combatSpells[i]
  20. if i < arrsize('$combatSpells'):
  21. if spellKnown[$ThisSpellName] = 1:
  22. $SpellListStr = $SpellListStr + "
  23. <tr>
  24. <td align='left'><a href=""EXEC: cls & gs 'castSpell', '<<$ThisSpellName>>'& xgt 'fight','sta' & act 'Physical attacks':gt'boxing' & act 'Magic attacks':gt'magik'""><<$spellName[$ThisSpellName]>></a></td>
  25. <td align='right'><<spellMana[$ThisSpellName]>></td>
  26. <td align='left'><<$spellDesc[$ThisSpellName]>></td>
  27. </tr>"
  28. numSpellsKnown += 1
  29. end
  30. i += 1
  31. jump 'CombatSpellLoop'
  32. end
  33. $SpellListStr = $SpellListStr + "
  34. </table>
  35. </center>"
  36. if numSpellsKnown = 0:
  37. "No combat spells known."
  38. else
  39. *pl func('cleanHTML',$SpellListStr)
  40. end
  41. killvar 'i'
  42. killvar 'numSpellsKnown'
  43. killvar '$ThisSpellName'
  44. killvar '$SpellListStr'
  45. --- magik ---------------------------------