Advertisement
Skymagnum

Untitled

Apr 26th, 2013
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local combat = createCombatObject()
  2. setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
  3. setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, 18)
  4. setCombatParam(combat, COMBAT_PARAM_EFFECT, 49)
  5. setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -8.10, -280, -8.40, -280)
  6.  
  7. combat_arr = {
  8. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  9. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  10. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  11. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  12. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  13. {0, 0, 0, 0, 1, 3, 0, 0, 0, 0, 0},
  14. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  15. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  16. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  17. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
  18. {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
  19. }
  20.  
  21. local combat_area = createCombatArea(combat_arr)
  22. setCombatArea(combat, combat_area)
  23.  
  24. function onTargetTile(cid, pos)
  25.     doSendDistanceShoot(pos, getThingPos(getCreatureTarget(cid)), 18)
  26.     doSendDistanceShoot(pos, getThingPos(getCreatureTarget(cid)), 18)
  27.     doSendDistanceShoot(pos, getThingPos(getCreatureTarget(cid)), 18)
  28. end
  29.  
  30. setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile")
  31.  
  32. function onCastSpell(cid, var)
  33.     return doCombat(cid, combat, var)
  34. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement