TheU5erPL

Skrypt na CobbleX

Jan 18th, 2015
372
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.80 KB | None | 0 0
  1. on load:
  2. set {cobblexcrafting} to "&8&lCobble&2&lX"
  3. new Recipe {cobblexcrafting};
  4. {cobblexcrafting}.Recipe.registerIngredient{1, 64 cobble};
  5. {cobblexcrafting}.Recipe.registerIngredient{2, 64 cobble};
  6. {cobblexcrafting}.Recipe.registerIngredient{3, 64 cobble};
  7. {cobblexcrafting}.Recipe.registerIngredient{4, 64 cobble};
  8. {cobblexcrafting}.Recipe.registerIngredient{5, 64 cobble};
  9. {cobblexcrafting}.Recipe.registerIngredient{6, 64 cobble};
  10. {cobblexcrafting}.Recipe.registerIngredient{7, 64 cobble};
  11. {cobblexcrafting}.Recipe.registerIngredient{8, 64 cobble};
  12. {cobblexcrafting}.Recipe.registerIngredient{9, 64 cobble};
  13. {cobblexcrafting}.Recipe.registerResult{2 lapis ore of thorns 10 named "&8&lCobble&2&lX"};
  14. {cobblexcrafting}.Recipe.register{};
  15.  
  16. on place of lapis ore:
  17. if name of player's tool is "&8&lCobble&2&lX":
  18. if player's tool is enchanted with thorns 10:
  19. set {cobblex::%event-block%} to true
  20. send "&aPostawiles &8&lCobble&2&lX&r&a!"
  21. stop
  22.  
  23. on break of lapis ore:
  24. if {cobblex::%event-block%} is true:
  25. cancel event
  26. set event-block to air
  27. set {cobblex::%event-block%} to false
  28. run player command "/cobblex losuj" as op
  29. stop
  30.  
  31. command /cobblex [<text>]:
  32. trigger:
  33. if arg 1 is not set:
  34. if player has permission "cobblex.admin":
  35. send "&3Komendy Admina Cobblex:"
  36. send "&8/cobblex daj - dostajesz 1 CobbleX"
  37. send "&8/cobblex losuj - dostajesz losowy item, ktory dropi z cobblex"
  38. send "&8/cobblex crafting - crafting CobbleX'a"
  39. else:
  40. wait 1 tick
  41. open chest with 3 rows named "&9&lCrafting &8&lCobble&2&lX" to player
  42. wait 2 ticks
  43. format slot 2 of player with 64 of cobble named "&764 Bruku" to be unstealable
  44. format slot 3 of player with 64 of cobble named "&764 Bruku" to be unstealable
  45. format slot 4 of player with 64 of cobble named "&764 Bruku" to be unstealable
  46. format slot 11 of player with 64 of cobble named "&764 Bruku" to be unstealable
  47. format slot 12 of player with 64 of cobble named "&764 Bruku" to be unstealable
  48. format slot 13 of player with 64 of cobble named "&764 Bruku" to be unstealable
  49. format slot 20 of player with 64 of cobble named "&764 Bruku" to be unstealable
  50. format slot 21 of player with 64 of cobble named "&764 Bruku" to be unstealable
  51. format slot 22 of player with 64 of cobble named "&764 Bruku" to be unstealable
  52. format slot 15 of player with 2 of lapis ore of thorns 10 named "&8&lCobble&2&lX" to be unstealable
  53. if arg 1 is "crafting":
  54. wait 1 tick
  55. open chest with 3 rows named "&9&lCrafting &8&lCobble&2&lX" to player
  56. wait 2 ticks
  57. format slot 2 of player with 64 of cobble named "&764 Bruku" to be unstealable
  58. format slot 3 of player with 64 of cobble named "&764 Bruku" to be unstealable
  59. format slot 4 of player with 64 of cobble named "&764 Bruku" to be unstealable
  60. format slot 11 of player with 64 of cobble named "&764 Bruku" to be unstealable
  61. format slot 12 of player with 64 of cobble named "&764 Bruku" to be unstealable
  62. format slot 13 of player with 64 of cobble named "&764 Bruku" to be unstealable
  63. format slot 20 of player with 64 of cobble named "&764 Bruku" to be unstealable
  64. format slot 21 of player with 64 of cobble named "&764 Bruku" to be unstealable
  65. format slot 22 of player with 64 of cobble named "&764 Bruku" to be unstealable
  66. format slot 15 of player with 2 of lapis ore of thorns 10 named "&8&lCobble&2&lX" to be unstealable
  67. if arg 1 is "give" or "daj" or "wez":
  68. if player doesn't have permission "cobblex.admin":
  69. send "&4Blad: &cNie masz uprawnien!"
  70. stop
  71. if player has permission "cobblex.daj":
  72. give 1 lapis ore of thorns 10 named "&8&lCobble&2&lX" to player
  73. stop
  74. if arg 1 is "losuj":
  75. if player is not an op:
  76. send "&4Blad: &cNie masz uprawnien!"
  77. stop
  78. chance of 5%:
  79. drop 1 beacon at player
  80. send "&9Gratulacje! Trafiles na &7beacon&9!"
  81. stop
  82. chance of 10%:
  83. drop 2 enchanted golden apple at player
  84. send "&9Gratulacje! Trafiles na &72 koxy&9!"
  85. stop
  86. chance of 10%:
  87. drop 2 bookshelf at player
  88. send "&9Gratulacje! Trafiles na &72 polki z ksiazkami&9!"
  89. stop
  90. chance of 10%:
  91. drop 2 golden apple at player
  92. send "&9Gratulacje! Trafiles na &72 refile&9!"
  93. stop
  94. chance of 10%:
  95. drop 20 diamond at player
  96. send "&9Gratulacje! Trafiles na &720 diaxow&9!"
  97. stop
  98. chance of 10%:
  99. drop 20 emerald at player
  100. send "&9Gratulacje! Trafiles na &720 szmaragdow&9!"
  101. stop
  102. chance of 20%:
  103. drop 3 ender pearl at player
  104. send "&9Gratulacje! Trafiles na &73 perly&9!"
  105. stop
  106. chance of 20%:
  107. drop 15 tnt at player
  108. send "&9Gratulacje! Trafiles na &715 tnt&9!"
  109. stop
  110. chance of 20%:
  111. drop 20 glowstone at player
  112. send "&9Gratulacje! Trafiles na &720 glowstone'a&9!"
  113. stop
Advertisement
Add Comment
Please, Sign In to add comment