Guest User

Untitled

a guest
Jan 23rd, 2018
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.64 KB | None | 0 0
  1. Sub CheckForDead
  2. /declare corpseID int local
  3. /declare rezIndex int local
  4. /if (${SpawnCount[corpse radius 100]}) {
  5. /for rezIndex 1 to ${SpawnCount[pc corpse radius 100]}
  6. /varset corpseID ${NearestSpawn[${rezIndex},pc corpse radius 100].ID}
  7. /if (${Spawn[${corpseID}].Deity.ID} && !${rezTimer${corpseID}}) {
  8. /call AddToList rezList ${corpseID}
  9. /if ( ${Macro.Return.Equal[1]} ) {
  10. /echo New corpse detected! >> ${Spawn[${corpseID}].DisplayName} <<
  11. }
  12. }
  13. /next rezIndex
  14. }
  15. /return
  16.  
  17. Sub RezDead
  18. /declare tempID string local
  19. /declare i int local
  20. /if ( ${rezList.Find[[]} ) {
  21. /if ( ${rezList.Find[[]}>1 ) /varset rezList ${rezList.Right[-${Math.Calc[${rezList.Find[[]}-1]}]}
  22. /for i 1 to ${rezList.Count[[]}
  23. /varset tempID ${rezList.Arg[${i},[].Left[-1]}
  24. /if (${rezTimer${tempID}} > 1) {
  25. /echo ${rezTimer${tempID}} seconds left on ${Spawn[${tempID}].Name} timer
  26. /next i
  27. }
  28. /if (${Me.AltAbility[Blessing of Resurrection]} && ${Me.AltAbilityReady[Blessing of Resurrection]}) {
  29. /if ( !${Spawn[${tempID}].Type.Equal[corpse]} ) {
  30. /call DeleteFromList rezList ${tempID}
  31. }
  32. /squelch /target id ${tempID}
  33. /delay 1s ${Target.ID}==${tempID}
  34. /corpse
  35. /echo I am attempting to resurrect ${Target.Name} in my radius
  36. /if (${Defined[rezTimer${tempID}]} && ${rezTimer${tempID}} == 0) {
  37. /varset rezTimer${tempID} 600
  38. } else {
  39. /declare rezTimer${tempID} timer outer 600
  40. }
  41. /call Cast "Blessing of Resurrection" alt 10s
  42. /call DeleteFromList rezList ${tempID}
  43. }
  44. /next i
  45. }
  46. /return
Add Comment
Please, Sign In to add comment