MrBrun0_

MineShop

May 10th, 2017
293
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.50 KB | None | 0 0
  1. #Config
  2. options:
  3. #%{pontos.%player%}% é a variavel dos pontos, caso for adicionar na
  4. #scoreboard use %{pontos.%loop-player%}% caso for a scoreboard com loop se não for use %{pontos.%player%}%
  5.  
  6. #True = Ativado / False = Desativado
  7. category01: true
  8. category02: false
  9. category03: false
  10. category04: false
  11. category05: false
  12. category06: false
  13. category07: false
  14. category08: false
  15. category09: false
  16. category10: false
  17. #Mensagem ao tentar entrar em uma categoria desativada
  18. Menssagem-Category: &cCategoria não feita ainda, aguarde...
  19. #Menu Title
  20. menu-title: &8MineKibedShop
  21. #Shop Name/Lore/Item
  22. points-shop-name: &6Seus Pontos
  23. points-shop-lore: &f%{pontos.%player%}% &fPontos
  24. points-shop-item: gold nugget
  25. points-shop-slot: 4
  26.  
  27. #Category Name/Lore/Item
  28. category01-name: &aBlocos
  29. category01-lore: &7Compre Blocos
  30. category01-item: grass
  31. category01-slot: 20
  32.  
  33. category02-name: &c-//-
  34. category02-lore: &cCategoria Não Disponivel
  35. category02-item: iron bars
  36. category02-slot: 21
  37.  
  38. category03-name: &c-//-
  39. category03-lore: &cCategoria Não Disponivel
  40. category03-item: iron bars
  41. category03-slot: 22
  42.  
  43. category04-name: &c-//-
  44. category04-lore: &cCategoria Não Disponivel
  45. category04-item: iron bars
  46. category04-slot: 23
  47.  
  48. category05-name: &c-//-
  49. category05-lore: &cCategoria Não Disponivel
  50. category05-item: iron bars
  51. category05-slot: 24
  52.  
  53. category06-name: &c-//-
  54. category06-lore: &cCategoria Não Disponivel
  55. category06-item: iron bars
  56. category06-slot: 29
  57.  
  58. category07-name: &c-//-
  59. category07-lore: &cCategoria Não Disponivel
  60. category07-item: iron bars
  61. category07-slot: 30
  62.  
  63. category08-name: &c-//-
  64. category08-lore: &cCategoria Não Disponivel
  65. category08-item: iron bars
  66. category08-slot: 31
  67.  
  68. category09-name: &c-//-
  69. category09-lore: &cCategoria Não Disponivel
  70. category09-item: iron bars
  71. category09-slot: 32
  72.  
  73. category10-name: &c-//-
  74. category10-lore: &cCategoria Não Disponivel
  75. category10-item: iron bars
  76. category10-slot: 33
  77.  
  78. #Functions
  79. function CheckPluginVersion(https: text) :: boolean:
  80. if text from url "https://pastebin.com/raw/7pjekYRn" is not "0.3":
  81. return false
  82. else:
  83. return true
  84.  
  85. #Não Mexer
  86.  
  87. variables:
  88.  
  89. {pontos.%player%} = 0
  90.  
  91. command /pontos [<text>] [<player>] [<integer>]:
  92. trigger:
  93. if player has permission "admin.cash":
  94. if arg 1 is not set:
  95. if arg 2 is not set:
  96. send "&6Você tem &f%{pontos.%player%}% &6pontos"
  97.  
  98. if arg 1 is "enviar":
  99. if arg 2 is set:
  100. add arg 3 to {pontos.%arg-2%}
  101. send "&6Você enviou &f%arg-3% pontos para &f%arg-2%"
  102. send "&6Voce recebeu &f%arg-3% pontos de &f%player%" to arg 2
  103. else:
  104. send "&cUse /pontos enviar <nick> <quantidade>"
  105. if arg 1 is "remover":
  106. if arg 2 is set:
  107. remove arg 3 from {pontos.%arg-2%}
  108. send "&cVocê remove &f%arg-3% pontos de &f%arg-2%"
  109. else:
  110. send "&cUse /pontos remover <nick> <quantidade>"
  111. else:
  112. send "&6Você tem &f%{pontos.%player%}% &6pontos"
  113.  
  114. #Pode Mexer
  115. command /shop:
  116. trigger:
  117. open chest with 6 rows named "{@menu-title}" to player
  118. wait 1 tick
  119. format slot {@points-shop-slot} of player with {@points-shop-item} named "{@points-shop-name}" with lore "{@points-shop-lore}" to be unstealable
  120. format slot {@category01-slot} of player with {@category01-item} named "{@category01-name}" with lore "{@category01-lore}" to close then run [execute player command "/category 01"]
  121. format slot {@category02-slot} of player with {@category02-item} named "{@category02-name}" with lore "{@category02-lore}" to close then run [execute player command "/category 02"]
  122. format slot {@category03-slot} of player with {@category03-item} named "{@category03-name}" with lore "{@category03-lore}" to close then run [execute player command "/category 03"]
  123. format slot {@category04-slot} of player with {@category04-item} named "{@category04-name}" with lore "{@category04-lore}" to close then run [execute player command "/category 04"]
  124. format slot {@category05-slot} of player with {@category05-item} named "{@category05-name}" with lore "{@category05-lore}" to close then run [execute player command "/category 05"]
  125. format slot {@category06-slot} of player with {@category06-item} named "{@category06-name}" with lore "{@category06-lore}" to close then run [execute player command "/category 06"]
  126. format slot {@category07-slot} of player with {@category07-item} named "{@category07-name}" with lore "{@category07-lore}" to close then run [execute player command "/category 07"]
  127. format slot {@category08-slot} of player with {@category08-item} named "{@category08-name}" with lore "{@category08-lore}" to close then run [execute player command "/category 08"]
  128. format slot {@category09-slot} of player with {@category09-item} named "{@category09-name}" with lore "{@category09-lore}" to close then run [execute player command "/category 09"]
  129. format slot {@category10-slot} of player with {@category10-item} named "{@category10-name}" with lore "{@category10-lore}" to close then run [execute player command "/category 10"]
  130.  
  131. command /comprar [<text>]:
  132. trigger:
  133. if arg 1 is "bloco01":
  134. if {pontos.%player%} >= 3:
  135. remove 3 from {pontos.%player%}
  136. execute console command "/give %player% grass 64"
  137. send "&6Você comprou &aBloco de Grama &8x64 &6por 3 pontos"
  138. else:
  139. send "&cVocê não tem pontos suficientes!"
  140.  
  141. #Acceptcommand
  142. command /category [<integer>]:
  143. trigger:
  144. if arg 1 is 01:
  145. if {@category01} is true:
  146. invoke "category01" from player
  147. else:
  148. send "{@Menssagem-Category}"
  149. if arg 1 is 02:
  150. if {@category02} is true:
  151. invoke "category02" from player
  152. else:
  153. send "{@Menssagem-Category}"
  154. if arg 1 is 03:
  155. if {@category03} is true:
  156. invoke "category03" from player
  157. else:
  158. send "{@Menssagem-Category}"
  159. if arg 1 is 04:
  160. if {@category04} is true:
  161. invoke "category04" from player
  162. else:
  163. send "{@Menssagem-Category}"
  164. if arg 1 is 05:
  165. if {@category05} is true:
  166. invoke "category05" from player
  167. else:
  168. send "{@Menssagem-Category}"
  169. if arg 1 is 06:
  170. if {@category06} is true:
  171. invoke "category06" from player
  172. else:
  173. send "{@Menssagem-Category}"
  174. if arg 1 is 07:
  175. if {@category07} is true:
  176. invoke "category07" from player
  177. else:
  178. send "{@Menssagem-Category}"
  179. if arg 1 is 08:
  180. if {@category08} is true:
  181. invoke "category08" from player
  182. else:
  183. send "{@Menssagem-Category}"
  184. if arg 1 is 09:
  185. if {@category09} is true:
  186. invoke "category09" from player
  187. else:
  188. send "{@Menssagem-Category}"
  189. if arg 1 is 10:
  190. if {@category10} is true:
  191. invoke "category10" from player
  192. else:
  193. send "{@Menssagem-Category}"
  194.  
  195. on load:
  196. if file "plugins/MineShop/info.yml" doesn't exists:
  197. create file "plugins/MineShop/info.yml"
  198. send "&8[&6MineShop&8] &cPasta MineShop ainda não criada, criando..." to console
  199. wait 2 seconds
  200. send "&8[&6MineShop&8] &aPasta MineShop criada!" to console
  201. send "&8[&6MineShop&8] &aDiretorio &6plugins/MineShop/info.txt" to console
  202. set "Info.Name" to "SKMineShop" in yaml file "plugins/MineShop/info.yml"
  203. set "Info.Version" to "0.2" in yaml file "plugins/MineShop/info.yml"
  204. set "Info.Author" to "MrBrun0_ // Brun0MasterBR" in yaml file "plugins/MineShop/info.yml"
  205. set "Info.Description" to "Skript/Plugin in shop gui" in yaml file "plugins/MineShop/info.yml"
  206. set "Info.Versione" to "Skript in fase Beta" in yaml file "plugins/MineShop/info.yml"
  207. set "Info.Diretory" to "plugins/Skript/scripts/Cash.sk" in yaml file "plugins/MineShop/info.yml"
  208. set "Info.Suport" to " " in yaml file "plugins/MineShop/info.yml"
  209. set "Info.Email" to "Email: [email protected]" in yaml file "plugins/MineShop/info.yml"
  210. set "Info.Skype" to "Skype: [email protected]" in yaml file "plugins/MineShop/info.yml"
  211. else:
  212. send "&8[&6MineShop&8] &cPasta MineShop encontrada..." to console
  213.  
  214. on load:
  215. set {_ver} to CheckPluginVersion("HTTPS")
  216. if {_ver} is true:
  217. send "&8[&6MineShop&8] &aSeu Plugin esta Atualizado. Versão atual: 0.3" to console
  218. else:
  219. send "&8[&6MineShop&8] &cSeu Plugin esta Desatualizado. Acesse www.youtube.com/brun0masterbr" to console
  220.  
  221. on join:
  222. set {_ver} to CheckPluginVersion("HTTPS")
  223. if {_ver} is false:
  224. if player has permission "admin.server":
  225. send "&8[&6MineShop&8] &cSeu Plugin esta Desatualizado. Acesse www.youtube.com/brun0masterbr" to player
  226. send "&8[&6MineShop&8] &cSeu Plugin esta Desatualizado. Acesse www.youtube.com/brun0masterbr" to console
Advertisement
Add Comment
Please, Sign In to add comment