Guest User

Untitled

a guest
Apr 26th, 2018
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.92 KB | None | 0 0
  1. package Person;
  2.  
  3. import javax.swing.*;
  4.  
  5. public class Attributs {
  6. /* public static Attributs getStreinth() {
  7. return streinth;
  8. }
  9.  
  10. public static Attributs getDextery() {
  11. return dextery;
  12. }
  13.  
  14. public static Attributs getVitality() {
  15. return vitality;
  16. }
  17.  
  18. public static Attributs getIntelligence() {
  19. return intelligence;
  20. }
  21.  
  22. public static Attributs getCharisma() {
  23. return charisma;
  24. }
  25.  
  26. public static Attributs getFaith() {
  27. return faith;
  28. }
  29. */
  30. private int value = 5;
  31. private String name = "";
  32. private String nameEn = "";
  33. private ImageIcon txtIcon; //текстовой
  34. private ImageIcon Icon; //картинка
  35.  
  36. private Attributs(int value, String name, ImageIcon txtIcon, ImageIcon icon,String nameEn){
  37. this.value = value;
  38. this.name = name;
  39. this.txtIcon = txtIcon;
  40. this.Icon = icon;
  41. this.nameEn = nameEn;
  42. }
  43. //гетеры
  44. public int getValue() {
  45. return value;
  46. }
  47.  
  48. public String getName() {
  49. return name;
  50. }
  51.  
  52. public String getNameEn() {
  53. return nameEn;
  54. }
  55.  
  56. public ImageIcon getTxtIcon() {
  57. return txtIcon;
  58. }
  59.  
  60. public ImageIcon getIcon() {
  61. return Icon;
  62. }
  63. // объекты, вписать иконки в ImageIcon(....)
  64. public Attributs streinth = new Attributs(5,"Сила",null,null,"Streinth");
  65. public Attributs dextery = new Attributs(5,"Ловкость",null,null,"Dextery");
  66. public Attributs vitality = new Attributs(5,"Выносливость", null,null,"Vitality");
  67. public Attributs intelligence = new Attributs(5,"Интеллект",new ImageIcon(),new ImageIcon(),"Intelligence");
  68. public Attributs charisma = new Attributs(5,"Харизма",new ImageIcon(),new ImageIcon(),"Charisma");
  69. public Attributs faith = new Attributs(5,"Вера",new ImageIcon(),new ImageIcon(),"Faith");
  70.  
  71. }
Add Comment
Please, Sign In to add comment