Guest User

Untitled

a guest
Nov 23rd, 2017
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. case "kill":
  2. HashSet<string> damageType = new HashSet<string>() { arg };
  3.  
  4. foreach (var actor in world.Selection.Actors)
  5. {
  6. if (actor.IsDead)
  7. continue;
  8.  
  9. var health = actor.TraitOrDefault<Health>();
  10. if (health != null)
  11. health.InflictDamage(actor, actor, new Damage(health.HP, damageType), true);
  12. }
  13.  
  14. // For Test
  15. Game.Debug("{0}", arg);
  16.  
  17. break;
Add Comment
Please, Sign In to add comment