armark1ng

Untitled

Sep 4th, 2016
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.83 KB | None | 0 0
  1. package com.rs.game.npc.vorago;
  2.  
  3. import com.rs.game.WorldObject;
  4. import com.rs.game.WorldTile;
  5.  
  6. @SuppressWarnings("serial")
  7. public class TheEndBomb extends WorldObject {
  8.  
  9. private transient Vorago vorago;
  10. private boolean active;
  11. private int charges;
  12.  
  13. public TheEndBomb(int id, int type, int rotation, WorldTile tile, Vorago vorago, int charges) {
  14. super(id, type, rotation, tile);
  15. this.vorago = vorago;
  16. this.charges = charges;
  17. }
  18.  
  19. public int getCharges() {
  20. return charges;
  21. }
  22.  
  23. public boolean decreaseCharges() {
  24. if (charges > 0) {
  25. charges--;
  26. if (charges == 0)
  27. active = false;
  28. return true;
  29. }
  30. return false;
  31. }
  32.  
  33. public boolean isActive() {
  34. return active;
  35. }
  36.  
  37. public void setActive(boolean active) {
  38. this.active = active;
  39. }
  40.  
  41. public Vorago getVorago() {
  42. return vorago;
  43. }
  44. }
Advertisement
Add Comment
Please, Sign In to add comment