Advertisement
L2-Irrelevant

PcAppearance

Mar 14th, 2022
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.73 KB | None | 0 0
  1. com.l2jfrozen.gameserver.model.actor.appearance.PcAppearance.java
  2. ==========================================================================
  3.  
  4.  
  5. package com.l2jfrozen.gameserver.model.actor.appearance;
  6.  
  7. public class PcAppearance
  8. {
  9. // =========================================================
  10. // Data Field
  11. private byte _face;
  12. private byte _hairColor;
  13. private byte _hairStyle;
  14. private boolean _sex; // Female true(1)
  15. /** true if the player is invisible */
  16. private boolean _invisible = false;
  17. /** The hexadecimal Color of players name (white is 0xFFFFFF) */
  18. private int _nameColor = 0xFFFFFF;
  19. /** The hexadecimal Color of players name (white is 0xFFFFFF) */
  20. private int _titleColor = 0xFFFF77;
  21.  
  22. // =========================================================
  23. // Constructor
  24. public PcAppearance(final byte Face, final byte HColor, final byte HStyle, final boolean Sex)
  25. {
  26. _face = Face;
  27. _hairColor = HColor;
  28. _hairStyle = HStyle;
  29. _sex = Sex;
  30. }
  31.  
  32. // =========================================================
  33. // Method - Public
  34.  
  35. // =========================================================
  36. // Method - Private
  37.  
  38. // =========================================================
  39. // Property - Public
  40. public final byte getFace()
  41. {
  42. return _face;
  43. }
  44.  
  45. /**
  46. * @param value
  47. */
  48. public final void setFace(final int value)
  49. {
  50. _face = (byte) value;
  51. }
  52.  
  53. public final byte getHairColor()
  54. {
  55. return _hairColor;
  56. }
  57.  
  58. /**
  59. * @param value
  60. */
  61. public final void setHairColor(final int value)
  62. {
  63. _hairColor = (byte) value;
  64. }
  65.  
  66. public final byte getHairStyle()
  67. {
  68. return _hairStyle;
  69. }
  70.  
  71. /**
  72. * @param value
  73. */
  74. public final void setHairStyle(final int value)
  75. {
  76. _hairStyle = (byte) value;
  77. }
  78.  
  79. public final boolean getSex()
  80. {
  81. return _sex;
  82. }
  83.  
  84. /**
  85. * @param isfemale
  86. */
  87. public final void setSex(final boolean isfemale)
  88. {
  89. _sex = isfemale;
  90. }
  91.  
  92. public void setInvisible()
  93. {
  94. _invisible = true;
  95. }
  96.  
  97. public void setVisible()
  98. {
  99. _invisible = false;
  100. }
  101.  
  102. public boolean getInvisible()
  103. {
  104. return _invisible;
  105. }
  106.  
  107. public int getNameColor()
  108. {
  109. return _nameColor;
  110. }
  111.  
  112. public void setNameColor(final int nameColor)
  113. {
  114. _nameColor = nameColor;
  115. }
  116.  
  117. public void setNameColor(final int red, final int green, final int blue)
  118. {
  119. _nameColor = (red & 0xFF) + ((green & 0xFF) << 8) + ((blue & 0xFF) << 16);
  120. }
  121.  
  122. public int getTitleColor()
  123. {
  124. return _titleColor;
  125. }
  126.  
  127. public void setTitleColor(final int titleColor)
  128. {
  129. _titleColor = titleColor;
  130. }
  131.  
  132. public void setTitleColor(final int red, final int green, final int blue)
  133. {
  134. _titleColor = (red & 0xFF) + ((green & 0xFF) << 8) + ((blue & 0xFF) << 16);
  135. }
  136. }
  137.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement