054_atakB1 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243
  1. # atakB1
  2. <<<<<<< 054_atakB1
  3. if $ARGS[0] = 'atak':
  4. cla
  5. !расчет попадания уворота
  6. set poSp = speedV * 20/100
  7. set uvAg = agil * 20/100
  8. set poBox = reactV * 20/100
  9. set uvBox = react * 20/100
  10. set popad = RAND(reactV - poBox, reactV + poBox) + RAND(speedV-poSp, speedV + poSp) + bonusShV
  11. set uvorot = RAND(react - uvBox, react + uvBox) + RAND(agil-uvAg, agil + uvAg)
  12. set uvorKoef = uvorot * 50/100
  13. set popKoef = popad * 50/100
  14. if popad > uvorot:
  15. if popad >= uvorot + uvorKoef:
  16. !крит, очень точное попадание
  17. '<B><font color = green>critical hits</font></B>'
  18. gs 'atakB1','uronKrit'
  19. end
  20. if popad < uvorot+uvorKoef:
  21. !нормальное попадание
  22. !атаковал противник
  23. '<B><font color = green>Contact</font></B>'
  24. gs 'atakB1','uron'
  25. end
  26. end
  27. if popad <= uvorot:
  28. '<B><font color = red>is washed</font></B>'
  29. end
  30. =======
  31. if $ARGS[0]='atak':
  32. cla
  33. !payment hit dodge
  34. set poSp = speedV*20/100
  35. set uvAg = agil*20/100
  36. set poBox = reactV*20/100
  37. set uvBox = react*20/100
  38. set popad = RAND (reactV-poBox,reactV+poBox) + RAND (speedV-poSp,speedV+poSp) + bonusShV
  39. set uvorot = RAND (react-uvBox,react+uvBox) + RAND (agil-uvAg,agil+uvAg)
  40. set uvorKoef = uvorot*50/100
  41. set popKoef = popad*50/100
  42. if popad > uvorot:
  43. if popad >= uvorot+uvorKoef:
  44. !Crete, very direct hit
  45. '<B><font color=green>Critical hits</font></B>'
  46. gs'atakB1','uronKrit'
  47. end
  48. if popad < uvorot+uvorKoef:
  49. !normal hit
  50. !attack the enemy
  51. '<B><font color=green>EYE</font></B>'
  52. gs'atakB1','uron'
  53. end
  54. end
  55. if popad <= uvorot:
  56. '<B><font color=red>LOST</font></B>'
  57. end
  58. >>>>>>> 054_atakB1
  59. end
  60. <<<<<<< 054_atakB1
  61. if $ARGS[0] = 'uronKrit':
  62. =======
  63. if $ARGS[0]='uronKrit':
  64. >>>>>>> 054_atakB1
  65. cla
  66. set damDef = defenceV/100
  67. <<<<<<< 054_atakB1
  68. set damKoef = damDef * 20/100
  69. set damage = RAND(damDef + damKoef, damDef + damKoef * 2)
  70. gs 'atakB1','damage'
  71. =======
  72. set damKoef = damDef*20/100
  73. set damage = RAND(damDef+damKoef,damDef+damKoef*2)
  74. gs'atakB1','damage'
  75. >>>>>>> 054_atakB1
  76. end
  77. <<<<<<< 054_atakB1
  78. if $ARGS[0] = 'uron':
  79. =======
  80. if $ARGS[0]='uron':
  81. >>>>>>> 054_atakB1
  82. cla
  83. set damDef = defenceV/100
  84. <<<<<<< 054_atakB1
  85. set damKoef = damDef * 20/100
  86. set damage = RAND(damDef - damKoef, damDef + damKoef)
  87. gs 'atakB1','damage'
  88. =======
  89. set damKoef = damDef*20/100
  90. set damage = RAND(damDef-damKoef,damDef+damKoef)
  91. gs'atakB1','damage'
  92. >>>>>>> 054_atakB1
  93. end
  94. <<<<<<< 054_atakB1
  95. if $ARGS[0] = 'damage':
  96. cla
  97. if defence <= 0 and klon <= 0 and unmaterial <= 0 and barier <= 0:
  98. if dospeh > 0: set damage -= dospehDefV & set dospehEn -= 1
  99. if damage < 0: set damage = 0
  100. Set health -= damage
  101. !Set manna -= damageM
  102. if eleShV > 0:
  103. set stun = RAND(eleShV, eleShV * 3)
  104. '<B><font color = red>Protection of the enemy paralyze you <<stun>> rounds</font></B>'
  105. end
  106. '<B><font color = red>Protection of the enemy caused you damage <<damage>> units</font></B>'
  107. !'<B><font color = red>caused damage your manna <<damageM>> units</font></B>'
  108. if zerkalo > 0:
  109. set zerkalo -= 1
  110. set defenceV -= damage
  111. '<B><font color = green>You are reflected damage from the defense and protection of the enemy received <<damage>> points of damage</font></B>'
  112. end
  113. !xgt 'fight','sta'
  114. end
  115. if defence > 0 and klon <= 0 and unmaterial <= 0:
  116. !set damSum = damage + damageM
  117. !Set defence -= damSum
  118. Set defence -= damage
  119. '<B><font color = red>your defense harmed <<damage>> units from the defense</font></B>'
  120. !xgt 'fight','sta'
  121. end
  122. if klon > 0 and unmaterial <= 0:
  123. set klon -= 1
  124. '<B><font color = red>destroy your clone</font></B>'
  125. !xgt 'fight','sta'
  126. end
  127. if unmaterial > 0:
  128. set unmaterial -= 1
  129. '<B><font color = green>Beat the defense went through you. YOU is not material</font></B>'
  130. !xgt 'fight','sta'
  131. end
  132. if barier > 0:
  133. !барьер именитета для урона
  134. if barier >= damage:
  135. '<B><font color = green>You can easily withstand the impact of the defense</font></B>'
  136. !xgt 'fight','sta'
  137. end
  138. if barier < damage:
  139. !Set manna -= damageM
  140. !Set health -= damage
  141. Set health -= damage
  142. if eleShV > 0:
  143. set stun = RAND(eleShV, eleShV * 3)
  144. '<B><font color = red>Protection of the enemy paralyze you <<stun>> rounds</font></B>'
  145. end
  146. '<B><font color = red>You have harmed <<damage>> units from the defense</font></B>'
  147. !'<B><font color = red>caused damage your manna <<damageM>> units</font></B>'
  148. if zerkalo > 0:
  149. set zerkalo -= 1
  150. set defenceV -= damage
  151. '<B><font color = green>You are repelled enemy damage and protection received <<damage>> points of damage</font></B>'
  152. end
  153. end
  154. !xgt 'fight','sta'
  155. end
  156. =======
  157. if $ARGS[0]='damage':
  158. cla
  159. if defence <= 0 and klon <= 0 and unmaterial <= 0 and barier <= 0:
  160. if dospeh > 0:set damage = damage - dospehDefV&set dospehEn = dospehEn - 1
  161. if damage < 0:set damage = 0
  162. Set health = health - damage
  163. !Set manna = manna - damageM
  164. if eleShV > 0:
  165. set stun = RAND (eleShV,eleShV*3)
  166. '<B><font color=red>Protect your enemy paralyzed on <<stun>> Rounds</font></B>'
  167. end
  168. '<B><font color=red>Protect your enemy inflicted damage <<damage>> units</font></B>'
  169. !'<B><font color=red>Your manna harmed <<damageM>> units</font></B>'
  170. if zerkalo > 0:
  171. set zerkalo = zerkalo - 1
  172. set defenceV = defenceV - damage
  173. '<B><font color=green>You have reflected the damage done by the defense <<damage>> points of damage</font></B>'
  174. end
  175. !xgt'fight','sta'
  176. end
  177. if defence > 0 and klon <= 0 and unmaterial <= 0:
  178. !set damSum = damage + damageM
  179. !Set defence = defence - damSum
  180. Set defence = defence - damage
  181. '<B><font color=red>Your defense harmed <<damage>> units of the defense</font></B>'
  182. !xgt'fight','sta'
  183. end
  184. if klon > 0 and unmaterial <= 0:
  185. set klon = klon - 1
  186. '<B><font color=red>Destroy your clone</font></B>'
  187. !xgt'fight','sta'
  188. end
  189. if unmaterial > 0:
  190. set unmaterial = unmaterial - 1
  191. '<B><font color=green>Beat the defense went through you. YOU are not material</font></B>'
  192. !xgt'fight','sta'
  193. end
  194. if barier > 0:
  195. !imeniteta barrier for damage
  196. if barier >= damage:
  197. '<B><font color=green>You can easily withstand the impact of the defense</font></B>'
  198. !xgt'fight','sta'
  199. end
  200. if barier < damage:
  201. !Set manna = manna - damageM
  202. !Set health = health - damage
  203. Set health = health - damage
  204. if eleShV > 0:
  205. set stun = RAND (eleShV,eleShV*3)
  206. '<B><font color=red>Protect your enemy paralyzed on <<stun>> Rounds</font></B>'
  207. end
  208. '<B><font color=red>You harmed <<damage>> units of the defense</font></B>'
  209. !'<B><font color=red>Your manna harmed <<damageM>> units</font></B>'
  210. if zerkalo > 0:
  211. set zerkalo = zerkalo - 1
  212. set defenceV = defenceV - damage
  213. '<B><font color=green>You have reflected damage and the defense was <<damage>> points of damage</font></B>'
  214. end
  215. end
  216. !xgt'fight','sta'
  217. end
  218. >>>>>>> 054_atakB1
  219. end
  220. --- atakB1 ---------------------------------