You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

90 lines
2.0 KiB

  1. package structures.basic;
  2. /**
  3. * This is the base representation of a Card which is rendered in the player's hand.
  4. * A card has an id, a name (cardname) and a manacost. A card then has a large and mini
  5. * version. The mini version is what is rendered at the bottom of the screen. The big
  6. * version is what is rendered when the player clicks on a card in their hand.
  7. *
  8. * @author Dr. Richard McCreadie
  9. *
  10. */
  11. public class Card {
  12. int id;
  13. String cardname;
  14. int manacost;
  15. MiniCard miniCard;
  16. BigCard bigCard;
  17. boolean isCreature;
  18. String unitConfig;
  19. public Card() {};
  20. public Card(int id, String cardname, int manacost, MiniCard miniCard, BigCard bigCard, boolean isCreature, String unitConfig) {
  21. super();
  22. this.id = id;
  23. this.cardname = cardname;
  24. this.manacost = manacost;
  25. this.miniCard = miniCard;
  26. this.bigCard = bigCard;
  27. this.isCreature = isCreature;
  28. this.unitConfig = unitConfig;
  29. }
  30. public int getId() {
  31. return id;
  32. }
  33. public void setId(int id) {
  34. this.id = id;
  35. }
  36. public String getCardname() {
  37. return cardname;
  38. }
  39. public void setCardname(String cardname) {
  40. this.cardname = cardname;
  41. }
  42. public int getManacost() {
  43. return manacost;
  44. }
  45. public void setManacost(int manacost) {
  46. this.manacost = manacost;
  47. }
  48. public MiniCard getMiniCard() {
  49. return miniCard;
  50. }
  51. public void setMiniCard(MiniCard miniCard) {
  52. this.miniCard = miniCard;
  53. }
  54. public BigCard getBigCard() {
  55. return bigCard;
  56. }
  57. public void setBigCard(BigCard bigCard) {
  58. this.bigCard = bigCard;
  59. }
  60. public boolean getIsCreature() {
  61. return isCreature;
  62. }
  63. public void setIsCreature(boolean isCreature) {
  64. this.isCreature = isCreature;
  65. }
  66. public void setCreature(boolean isCreature) {
  67. this.isCreature = isCreature;
  68. }
  69. public boolean isCreature() {
  70. return isCreature;
  71. }
  72. public String getUnitConfig() {
  73. return unitConfig;
  74. }
  75. public void setUnitConfig(String unitConfig) {
  76. this.unitConfig = unitConfig;
  77. }
  78. }