PlayerAbilities.java 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. package pathgame.gameplay;
  2. public class PlayerAbilities
  3. {
  4. private final String name;
  5. private final int fasterGrass;
  6. private final int fasterForest;
  7. private final int fasterShallowWater;
  8. private final int fasterDeepWater;
  9. private final int fasterHill;
  10. private final int fasterMountain;
  11. private final int fasterSwamp;
  12. public PlayerAbilities(String name, int fasterGrass, int fasterForest, int fasterShallowWater,
  13. int fasterDeepWater, int fasterHill, int fasterMountain, int fasterSwamp)
  14. {
  15. this.name = name;
  16. this.fasterGrass = fasterGrass;
  17. this.fasterForest = fasterForest;
  18. this.fasterShallowWater = fasterShallowWater;
  19. this.fasterDeepWater = fasterDeepWater;
  20. this.fasterHill = fasterHill;
  21. this.fasterMountain = fasterMountain;
  22. this.fasterSwamp = fasterSwamp;
  23. }
  24. public final static PlayerAbilities NORMAL = new PlayerAbilities("Normal", 0, 0, 0, 0, 0, 0, 0);
  25. public final static PlayerAbilities HIKER = new PlayerAbilities("Hiker", 0, 0, 0, 0, 1, 0, 0);
  26. public final static PlayerAbilities CLIMBER = new PlayerAbilities("Climber", 0, 0, 0, 0, 0, 1, 0);
  27. public final static PlayerAbilities HUNTER = new PlayerAbilities("Hunter", 0, 1, 0, 0, 0, 0, 0);
  28. public final static PlayerAbilities SWIMMER = new PlayerAbilities("Swimmer", 0, 0, 2, 0, 0, 0, 0);
  29. public final static PlayerAbilities SAILOR = new PlayerAbilities("Sailor", 0, 0, 0, 1, 0, 0, 0);
  30. public final static PlayerAbilities[] ABILITIES = new PlayerAbilities[]
  31. {
  32. NORMAL, HIKER, CLIMBER, HUNTER, SWIMMER, SAILOR
  33. };
  34. public int getFasterGrass()
  35. {
  36. return fasterGrass;
  37. }
  38. public int getFasterForest()
  39. {
  40. return fasterForest;
  41. }
  42. public int getFasterShallowWater()
  43. {
  44. return fasterShallowWater;
  45. }
  46. public int getFasterDeepWater()
  47. {
  48. return fasterDeepWater;
  49. }
  50. public int getFasterHill()
  51. {
  52. return fasterHill;
  53. }
  54. public int getFasterMountain()
  55. {
  56. return fasterMountain;
  57. }
  58. public int getFasterSwamp()
  59. {
  60. return fasterSwamp;
  61. }
  62. public String getName()
  63. {
  64. return name;
  65. }
  66. }