atakB1.qsrc 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. # atakB1
  2. menu_off = 1
  3. if $ARGS[0] = 'atak':
  4. cla
  5. !payment hit dodge
  6. poSp = speedV*20/100
  7. uvAg = pcs_agil*20/100
  8. poBox = reactV*20/100
  9. uvBox = pcs_react*20/100
  10. popad = RAND(reactV-poBox,reactV+poBox) + RAND(speedV-poSp,speedV+poSp) + bonusShV
  11. uvorot = RAND(pcs_react-uvBox,pcs_react+uvBox) + RAND(pcs_agil-uvAg,pcs_agil+uvAg)
  12. uvorKoef = uvorot*50/100
  13. popKoef = popad*50/100
  14. if popad > uvorot:
  15. if popad >= uvorot+uvorKoef:
  16. !Crete, very direct hit
  17. '<b><font color = green>Critical hits</font></b>'
  18. gs'atakB1','uronKrit'
  19. elseif popad < uvorot+uvorKoef:
  20. !Normal hit
  21. !He attacks the enemy
  22. '<b><font color = green>EYE</font></b>'
  23. gs'atakB1','uron'
  24. end
  25. elseif popad <= uvorot:
  26. '<b><font color = red>LOST</font></b>'
  27. end
  28. end
  29. if $ARGS[0] = 'uronKrit':
  30. cla
  31. damDef = defenceV/100
  32. damKoef = damDef*20/100
  33. damage = RAND(damDef+damKoef,damDef+damKoef*2)
  34. gs'atakB1','damage'
  35. end
  36. if $ARGS[0] = 'uron':
  37. cla
  38. damDef = defenceV/100
  39. damKoef = damDef*20/100
  40. damage = RAND(damDef-damKoef,damDef+damKoef)
  41. gs'atakB1','damage'
  42. end
  43. if $ARGS[0] = 'damage':
  44. cla
  45. if defence <= 0 and klon <= 0 and unmaterial <= 0 and barier <= 0:
  46. if dospeh > 0:damage = damage - dospehDefV & dospehEn = dospehEn - 1
  47. if damage < 0:damage = 0
  48. pcs_health = pcs_health - damage
  49. !pcs_manna = pcs_manna - damageM
  50. if eleShV > 0:
  51. stun = RAND(eleShV,eleShV*3)
  52. '<b><font color = red>Defense paralyzed you to <<stun>> Rounds</font></b>'
  53. end
  54. '<b><font color = red>Defense caused you damage <<damage>> units</font></b>'
  55. !'<b><font color = red>Your manna harmed <<damageM>> units</font></b>'
  56. if zerkalo > 0:
  57. zerkalo = zerkalo - 1
  58. defenceV = defenceV - damage
  59. '<b><font color = green>You have reflected the damage of the defense and the defense received <<damage>> points of damage</font></b>'
  60. end
  61. !xgt'fight','sta'
  62. end
  63. if defence > 0 and klon <= 0 and unmaterial <= 0:
  64. !damSum = damage + damageM
  65. !defence = defence - damSum
  66. defence = defence - damage
  67. '<b><font color = red>Your protection harmed <<damage>> units of the defense</font></b>'
  68. !xgt'fight','sta'
  69. end
  70. if klon > 0 and unmaterial <= 0:
  71. klon = klon - 1
  72. '<b><font color = red>It destroys your clone</font></b>'
  73. !xgt'fight','sta'
  74. end
  75. if unmaterial > 0:
  76. unmaterial = unmaterial - 1
  77. '<b><font color = green>Beat the defense went through you. YOU are not material</font></b>'
  78. !xgt'fight','sta'
  79. end
  80. if barier > 0:
  81. !imeniteta barrier for damage
  82. if barier >= damage:
  83. '<b><font color = green>You can easily withstand the impact of the defense</font></b>'
  84. !xgt'fight','sta'
  85. elseif barier < damage:
  86. !pcs_manna = pcs_manna - damageM
  87. !pcs_health = pcs_health - damage
  88. pcs_health = pcs_health - damage
  89. if eleShV > 0:
  90. stun = RAND(eleShV,eleShV*3)
  91. '<b><font color = red>Defense paralyzed you to <<stun>> Rounds</font></b>'
  92. end
  93. '<b><font color = red>You harmed <<damage>> units of the defense</font></b>'
  94. !'<b><font color = red>Your manna harmed <<damageM>> units</font></b>'
  95. if zerkalo > 0:
  96. zerkalo = zerkalo - 1
  97. defenceV = defenceV - damage
  98. '<b><font color = green>You have reflected damage and defense received <<damage>> points of damage</font></b>'
  99. end
  100. end
  101. !xgt'fight','sta'
  102. end
  103. end
  104. --- atakB1 ---------------------------------