1
0

atakA1 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. # atakA1
  2. if $ARGS[0] = 'atak':
  3. cla
  4. !payment hit dodge
  5. poSp = speedV*20/100
  6. uvAg = agil*20/100
  7. poBox = reactV*20/100
  8. uvBox = react*20/100
  9. popad = RAND(reactV-poBox,reactV+poBox) + RAND(speedV-poSp,speedV+poSp) + bonusShV
  10. uvorot = RAND(react-uvBox,react+uvBox) + RAND(agil-uvAg,agil+uvAg)
  11. uvorKoef = uvorot*50/100
  12. popKoef = popad*50/100
  13. if popad > uvorot:
  14. if popad >= uvorot+uvorKoef:
  15. !Crete, very direct hit
  16. '<b><font color = red>Critical hits</font></b>'
  17. xgt'atakA1','uronKrit'
  18. elseif popad < uvorot+uvorKoef:
  19. !Normal hit
  20. !He attacks the enemy
  21. '<b><font color = red>EYE</font></b>'
  22. xgt'atakA1','uron'
  23. end
  24. elseif popad <= uvorot:
  25. '<b><font color = green>LOST</font></b>'
  26. xgt'fight','sta'
  27. end
  28. end
  29. if $ARGS[0] = 'uronKrit':
  30. cla
  31. damKoef = damTipV*20/100
  32. damage = RAND(damTipV+damKoef,damTipV+damKoef*2)
  33. if damTipMV > 0:
  34. damKoefM = damTipMV*20/100
  35. damageM = RAND(damTipMV+damKoefM,damTipMV+damKoefM*2)
  36. end
  37. xgt'atakA1','damage'
  38. end
  39. if $ARGS[0] = 'uron':
  40. cla
  41. damKoef = damTipV*20/100
  42. damage = RAND(damTipV-damKoef,damTipV+damKoef)
  43. if damTipMV > 0:
  44. damKoefM = damTipMV*20/100
  45. damageM = RAND(damTipMV-damKoefM,damTipMV+damKoefM)
  46. end
  47. xgt'atakA1','damage'
  48. end
  49. if $ARGS[0] = 'damage':
  50. cla
  51. if defence <= 0 and klon <= 0 and unmaterial <= 0 and barier <= 0:
  52. if dospeh > 0:damage = damage - dospehDef & dospehEn = dospehEn - 1
  53. if damage < 0:damage = 0
  54. health = health - damage
  55. if hidanAtk = 1:
  56. hidanAtk = 0
  57. zerkaloV = zerkaloV + 50
  58. bloodV = bloodV + 50
  59. '<b><font color = red><<$boy>> drink your blood.</font></b>'
  60. end
  61. if damTipMV > 0:
  62. manna = manna - damageM
  63. manna = manna + damageM
  64. '<b><font color = red><<$boy>> swallowed <<damageM>> Units manna you.</font></b>'
  65. end
  66. if poisonAV = 1:
  67. poisonV = 50
  68. '<b><font color = red><<$boy>> hit the needle poisoned you.</font></b>'
  69. end
  70. !manna = manna - damageM
  71. if eleShV > 0:
  72. stun = RAND(eleShV,eleShV*3)
  73. '<b><font color = red>You paralyzed on <<stunV>> Rounds</font></b>'
  74. end
  75. '<b><font color = red><<$boy>> Damage caused to you <<damage>> units</font></b>'
  76. !'<b><font color = red>Your manna harmed <<damageM>> units</font></b>'
  77. if zerkalo > 0:
  78. zerkalo = zerkalo - 1
  79. healthV = healthV - damage
  80. '<b><font color = green>You are repelled and the damage <<$boy>> got a <<damage>> points of damage</font></b>'
  81. end
  82. xgt'fight','sta'
  83. end
  84. if defence > 0 and klon <= 0 and unmaterial <= 0:
  85. !damSum = damage + damageM
  86. !defence = defence - damSum
  87. defence = defence - damage
  88. '<b><font color = red>Your protection harmed <<damage>> units</font></b>'
  89. xgt'fight','sta'
  90. end
  91. if klon > 0 and unmaterial <= 0:
  92. klon = klon - 1
  93. '<b><font color = red>It destroys your clone</font></b>'
  94. xgt'fight','sta'
  95. end
  96. if unmaterial > 0:
  97. unmaterial = unmaterial - 1
  98. '<b><font color = green>Beat the enemy passed through you. YOU are not material</font></b>'
  99. xgt'fight','sta'
  100. end
  101. if barier > 0:
  102. !imeniteta barrier for damage
  103. if barier >= damage:
  104. '<b><font color = green>You can easily withstand the impact of the enemy</font></b>'
  105. xgt'fight','sta'
  106. elseif barier < damage:
  107. !manna = manna - damageM
  108. !health = health - damage
  109. health = health - damage
  110. if damTipM > 0:
  111. manna = manna - damageM
  112. mannaV = mannaV + damageM
  113. '<b><font color = green>You swallowed <<damageM>> manna enemy units.</font></b>'
  114. end
  115. if eleShV > 0:
  116. stun = RAND(eleShV,eleShV*3)
  117. '<b><font color = green><<$boy>> paralyzed <<stunV>> Rounds</font></b>'
  118. end
  119. if poisonAV = 1:
  120. poisonV = 50
  121. '<b><font color = red><<$boy>> hit the needle poisoned you.</font></b>'
  122. end
  123. '<b><font color = red>You have caused damage <<damage>> units</font></b>'
  124. !'<b><font color = red>Your manna harmed <<damageM>> units</font></b>'
  125. if zerkalo > 0:
  126. zerkalo = zerkalo - 1
  127. healthV = healthV - damage
  128. '<b><font color = green>You have reflected the damage and the opponent was <<damage>> points of damage</font></b>'
  129. end
  130. end
  131. xgt'fight','sta'
  132. end
  133. end
  134. if $ARGS[0] = 'atakW':
  135. cla
  136. !payment hit dodge
  137. poSp = speedV*20/100
  138. uvAg = agil*20/100
  139. poBox = reactV*20/100
  140. uvBox = react*20/100
  141. popad = RAND(reactV-poBox,reactV+poBox) + RAND(speedV-poSp,speedV+poSp)
  142. uvorot = RAND(react-uvBox,react+uvBox) + RAND(agil-uvAg,agil+uvAg)
  143. uvorKoef = uvorot*50/100
  144. popKoef = popad*50/100
  145. if popad > uvorot:
  146. if popad >= uvorot+uvorKoef:
  147. !Crete, very direct hit
  148. '<b><font color = red>Critical hits</font></b>'
  149. xgt'atakA1','uronKritW'
  150. elseif popad < uvorot+uvorKoef:
  151. !Normal hit
  152. '<b><font color = red>EYE</font></b>'
  153. xgt'atakA1','uronW'
  154. end
  155. elseif popad <= uvorot:
  156. '<b><font color = green>LOST</font></b>'
  157. xgt'fight','sta'
  158. end
  159. end
  160. if $ARGS[0] = 'uronKritW':
  161. cla
  162. damKoef = damTipV*20/100
  163. damage = RAND(damTipV+damKoef,damTipV+damKoef*2)
  164. damKoefM = damTipMV*20/100
  165. damageM = RAND(damTipMV+damKoefM,damTipMV+damKoefM*2)
  166. xgt'atakA1','damageW'
  167. end
  168. if $ARGS[0] = 'uronW':
  169. cla
  170. damKoef = damTipV*20/100
  171. damage = RAND(damTipV-damKoef,damTipV+damKoef)
  172. damKoefM = damTipMV*20/100
  173. damageM = RAND(damTipMV-damKoefM,damTipMV+damKoefM)
  174. xgt'atakA1','damageW'
  175. end
  176. if $ARGS[0] = 'damageW':
  177. cla
  178. if defence <= 0 and klon <= 0 and unmaterial <= 0 and barier <= 0:
  179. if dospeh > 0:damage = damage - dospehDef & dospehEn = dospehEn - 1
  180. if damage < 0:damage = 0
  181. health = health - damage
  182. manna = manna - damageM
  183. '<b><font color = green>You harmed <<damage>> units</font></b>'
  184. '<b><font color = green>You have caused damage to the enemy manna <<damageM>> units</font></b>'
  185. if zerkalo > 0:
  186. zerkalo = zerkalo - 1
  187. health = health - damage
  188. '<b><font color = red><<$boy>> reflected the damage and you get <<damage>> points of damage</font></b>'
  189. end
  190. xgt'fight','sta'
  191. end
  192. if defence > 0 and klon <= 0 and unmaterial <= 0:
  193. damSum = damage + damageM
  194. defence = defence - damSum
  195. !defenceV = defenceV - damage
  196. '<b><font color = green>You have caused damage <<damSum>> Protection of enemy units</font></b>'
  197. xgt'fight','sta'
  198. end
  199. if klon > 0 and unmaterial <= 0:
  200. klon = klon - 1
  201. '<b><font color = green>Destroyed enemy clone</font></b>'
  202. xgt'fight','sta'
  203. end
  204. if unmaterial > 0:
  205. unmaterial = unmaterial - 1
  206. '<b><font color = red>Your blow has passed through the body of the enemy. Opponents do not materials</font></b>'
  207. xgt'fight','sta'
  208. end
  209. if barier > 0:
  210. !imeniteta barrier for damage
  211. if barier >= damage:
  212. '<b><font color = red><<$boy>> easily weathered blow your</font></b>'
  213. xgt'fight','sta'
  214. elseif barier < damage:
  215. manna = manna - damageM
  216. health = health - damage
  217. !healthV = healthV - damage
  218. '<b><font color = green>You have caused damage <<damage>> units</font></b>'
  219. '<b><font color = green>You have caused damage to the enemy manna <<damageM>> units</font></b>'
  220. if zerkalo > 0:
  221. zerkalo = zerkalo - 1
  222. healthV = healthV - damage
  223. '<b><font color = red>Opponent reflected damage and you get <<damage>> points of damage</font></b>'
  224. end
  225. end
  226. xgt'fight','sta'
  227. end
  228. end
  229. --- atakA1 ---------------------------------