PlayerAbilities.java 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  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, 2, 4, 0);
  26. public final static PlayerAbilities HUNTER = new PlayerAbilities("Hunter", 0, 1, 0, 0, 0, 0, 1);
  27. public final static PlayerAbilities SWIMMER = new PlayerAbilities("Swimmer", 0, 0, 3, 0, 0, 0, 0);
  28. public final static PlayerAbilities SAILOR = new PlayerAbilities("Sailor", 0, 0, 0, 1, 0, 0, 0);
  29. public final static PlayerAbilities[] ABILITIES = new PlayerAbilities[]
  30. {
  31. NORMAL, HIKER, HUNTER, SWIMMER, SAILOR
  32. };
  33. public int getFasterGrass()
  34. {
  35. return fasterGrass;
  36. }
  37. public int getFasterForest()
  38. {
  39. return fasterForest;
  40. }
  41. public int getFasterShallowWater()
  42. {
  43. return fasterShallowWater;
  44. }
  45. public int getFasterDeepWater()
  46. {
  47. return fasterDeepWater;
  48. }
  49. public int getFasterHill()
  50. {
  51. return fasterHill;
  52. }
  53. public int getFasterMountain()
  54. {
  55. return fasterMountain;
  56. }
  57. public int getFasterSwamp()
  58. {
  59. return fasterSwamp;
  60. }
  61. public String getName()
  62. {
  63. return name;
  64. }
  65. }