CrownTable.java 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. /*
  2. * This program is free software: you can redistribute it and/or modify it under
  3. * the terms of the GNU General Public License as published by the Free Software
  4. * Foundation, either version 3 of the License, or (at your option) any later
  5. * version.
  6. *
  7. * This program is distributed in the hope that it will be useful, but WITHOUT
  8. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  9. * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
  10. * details.
  11. *
  12. * You should have received a copy of the GNU General Public License along with
  13. * this program. If not, see <http://www.gnu.org/licenses/>.
  14. */
  15. package net.sf.l2j.gameserver.datatables;
  16. import java.util.List;
  17. import javolution.util.FastList;
  18. /**
  19. * This class has just one simple function to return the item id of a crown
  20. * regarding to castleid
  21. *
  22. * @author evill33t
  23. */
  24. public class CrownTable
  25. {
  26. private static List<Integer> _crownList = new FastList<Integer>();
  27. public static List<Integer> getCrownList()
  28. {
  29. if(_crownList.isEmpty())
  30. {
  31. _crownList.add(6841); // Crown of the lord
  32. _crownList.add(6834); // Innadril
  33. _crownList.add(6835); // Dion
  34. _crownList.add(6836); // Goddard
  35. _crownList.add(6837); // Oren
  36. _crownList.add(6838); // Gludio
  37. _crownList.add(6839); // Giran
  38. _crownList.add(6840); // Aden
  39. _crownList.add(8182); // Rune
  40. _crownList.add(8183); // Schuttgart
  41. }
  42. return _crownList;
  43. }
  44. public static int getCrownId(int CastleId)
  45. {
  46. int CrownId=0;
  47. switch(CastleId)
  48. {
  49. // Gludio
  50. case 1:
  51. CrownId = 6838;
  52. break;
  53. // Dion
  54. case 2:
  55. CrownId = 6835;
  56. break;
  57. // Giran
  58. case 3:
  59. CrownId = 6839;
  60. break;
  61. // Oren
  62. case 4:
  63. CrownId = 6837;
  64. break;
  65. // Aden
  66. case 5:
  67. CrownId = 6840;
  68. break;
  69. // Innadril
  70. case 6:
  71. CrownId = 6834;
  72. break;
  73. // Goddard
  74. case 7:
  75. CrownId = 6836;
  76. break;
  77. // Rune
  78. case 8:
  79. CrownId = 8182;
  80. break;
  81. // Schuttgart
  82. case 9:
  83. CrownId = 8183;
  84. break;
  85. default:
  86. CrownId=0;
  87. break;
  88. }
  89. return CrownId;
  90. }
  91. }