FlupMC

Untitled

Aug 6th, 2017
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 18.22 KB | None | 0 0
  1. command /bet [<text>]:
  2. trigger:
  3. if arg-1 is not set:
  4. open chest with 3 rows named "&2&lROULETTE" to player
  5. wait 3 ticks
  6. if inventory name of player's current inventory is "&2&lROULETTE":
  7. loop integers from 0 to 26:
  8. format slot loop-number of player with white stained glass pane named "&r" to be unstealable
  9. if {roulette.igang} is true:
  10. format slot 13 of player with 166 named "&4&lIGANG" with lore "&cSpillet er allerede igang." to be unstealable
  11. stop
  12. if {roulette::%uuid of player%} is true:
  13. format slot 13 of player with 166 named "&4&lJOINET" with lore "&cDu er allerede joinet." to be unstealable
  14. stop
  15. format slot 11 of player with black stained glass pane named "&8&lSORT" with lore "&7Chance&8: &750%%||&7Ganger&8: &72x" to close then run [ make player execute command "bet sort"]
  16. format slot 13 of player with red stained glass pane named "&4&lRØD" with lore "&7Chance&8: &750%%||&7Ganger&8: &72x" to close then run [ make player execute command "bet rød"]
  17. format slot 15 of player with light green stained glass pane named "&4&lRØD" with lore "&7Chance&8: &73%%||&7Ganger&8: &710x" to close then run [ make player execute command "bet grøn"]
  18. if arg-1 is "Rød":
  19. if {roulette::%uuid of player%} is true:
  20. send "&8[&4Casino&8] &7Du kan kun bet 1 gang."
  21. stop
  22. if {nummer.roulette::%uuid of player%} is set:
  23. send "&8[&4Casino&8] &7Du kan kun bet 1 gang."
  24. stop
  25. set {nummer.roulette::%uuid of player%} to "Rød"
  26. close player's inventory
  27. send "&8&m--------------------------"
  28. send ""
  29. send "&7Skriv det antal penge du vil bette i chatten."
  30. send "&7Skriv 'Nej' i chatten, hvis du ikke vil."
  31. send ""
  32. send "&8&m--------------------------"
  33. if arg-1 is "Grøn":
  34. if {roulette::%uuid of player%} is true:
  35. send "&8[&4Casino&8] &7Du kan kun bet 1 gang."
  36. stop
  37. if {nummer.roulette::%uuid of player%} is set:
  38. send "&8[&4Casino&8] &7Du kan kun bet 1 gang."
  39. stop
  40. set {nummer.roulette::%uuid of player%} to "Grøn"
  41. close player's inventory
  42. send "&8&m--------------------------"
  43. send ""
  44. send "&7Skriv det antal penge du vil bette i chatten."
  45. send "&7Skriv 'Nej' i chatten, hvis du ikke vil."
  46. send ""
  47. send "&8&m--------------------------"
  48. if arg-1 is "Sort":
  49. if {roulette::%uuid of player%} is true:
  50. send "&8[&4Casino&8] &7Du kan kun bet 1 gang."
  51. stop
  52. if {nummer.roulette::%uuid of player%} is set:
  53. send "&8[&4Casino&8] &7Du kan kun bet 1 gang."
  54. stop
  55. set {nummer.roulette::%uuid of player%} to "Sort"
  56. close player's inventory
  57. send "&8&m--------------------------"
  58. send ""
  59. send "&7Skriv det antal penge du vil bette i chatten."
  60. send "&7Skriv 'Nej' i chatten, hvis du ikke vil."
  61. send ""
  62. send "&8&m--------------------------"
  63. on chat:
  64. cancel event
  65. if {nummer.roulette::%uuid of player%} is "Rød":
  66. if message is "Nej":
  67. delete {nummer.roulette::%uuid of player%}
  68. send "&8[&4Casino&8] &7Du gik ud af rouletten."
  69. stop
  70. else:
  71. execute player command "bete rød %message%"
  72. stop
  73. if {nummer.roulette::%uuid of player%} is "Sort":
  74. if message is "Nej":
  75. delete {nummer.roulette::%uuid of player%}
  76. send "&8[&4Casino&8] &7Du gik ud af rouletten."
  77. stop
  78. else:
  79. execute player command "bete sort %message%"
  80. stop
  81. if {nummer.roulette::%uuid of player%} is "Grøn":
  82. if message is "Nej":
  83. delete {nummer.roulette::%uuid of player%}
  84. send "&8[&4Casino&8] &7Du gik ud af rouletten."
  85. stop
  86. else:
  87. execute player command "bete grøn %message%"
  88. stop
  89. else:
  90. send "%player's displayname%&8: &7%message%"
  91. command /bete [<text>] [<number>]:
  92. trigger:
  93. if {roulette.igang} is set:
  94. send "&8[&4Casino&8] &7Du kan ikke joine når den allerede er igang."
  95. stop
  96. if {roulette::%uuid of player%} is set:
  97. send "&8[&4Casino&8] &7Du er allerede joinet"
  98. stop
  99. else:
  100. if arg-1 is not set:
  101. stop
  102. else:
  103. if arg-2 is not set:
  104. stop
  105. else:
  106. if arg-1 is "rød" or "red":
  107. if arg-2 is a number:
  108. if player's balance is greater or equal to arg-2:
  109. subtract arg-2 from player's balance
  110. send "&8[&4Casino&8] &7Du joinede &cRød&7 med et bet på &a$%arg-2%"
  111. set {rød.roulette::%uuid of player%} to true
  112. delete {sort.roulette::%uuid of player%}
  113. delete {grøn.roulette::%uuid of player%}
  114. set {roulette::%uuid of player%} to true
  115. set {penge.roulette::%uuid of player%} to arg-2
  116. delete {nummer.roulette::%uuid of player%}
  117. stop
  118. else:
  119. send "&8[&4Casino&8] &7Du har ikke nok penge"
  120. stop
  121. else:
  122. send "&8[&4Casino&8] &7Du skal skrive et rigtigt tal."
  123. stop
  124. if arg-1 is "sort" or "black":
  125. if arg-2 is a number:
  126. if player's balance is greater or equal to arg-2:
  127. subtract arg-2 from player's balance
  128. send "&8[&4Casino&8] &7Du joinede &8Sort&7 med et bet på &a$%arg-2%"
  129. set {sort.roulette::%uuid of player%} to true
  130. delete {rød.roulette::%uuid of player%}
  131. delete {grøn.roulette::%uuid of player%}
  132. set {roulette::%uuid of player%} to true
  133. set {penge.roulette::%uuid of player%} to arg-2
  134. delete {nummer.roulette::%uuid of player%}
  135. stop
  136. else:
  137. send "&8[&4Casino&8] &7Du har ikke nok penge"
  138. stop
  139. else:
  140. send "&8[&4Casino&8] &7Du skal skrive et rigtigt tal."
  141. stop
  142. if arg-1 is "grøn" or "green":
  143. if arg-2 is a number:
  144. if player's balance is greater or equal to arg-2:
  145. subtract arg-2 from player's balance
  146. send "&8[&4Casino&8] &7Du joinede &aGrøn&7 med et bet på &a$%arg-2%"
  147. set {grøn.roulette::%uuid of player%} to true
  148. delete {rød.roulette::%uuid of player%}
  149. delete {sort.roulette::%uuid of player%}
  150. set {roulette::%uuid of player%} to true
  151. set {penge.roulette::%uuid of player%} to arg-2
  152. delete {nummer.roulette::%uuid of player%}
  153. stop
  154. else:
  155. send "&8[&4Casino&8] &7Du har ikke nok penge"
  156. stop
  157. else:
  158. send "&8[&4Casino&8] &7Du skal skrive et rigtigt tal."
  159. stop
  160. command /rollsetloc [<text>]:
  161. permission: *
  162. permission message: &cDu har ikke adgang til dette.
  163. trigger:
  164. if arg-1 is "1":
  165. set {roll.location::1} to location of target block
  166. if arg-1 is "2":
  167. set {roll.location::2} to location of target block
  168. if arg-1 is "3":
  169. set {roll.location::3} to location of target block
  170. if arg-1 is "4":
  171. set {roll.location::4} to location of target block
  172. if arg-1 is "5":
  173. set {roll.location::5} to location of target block
  174. command /roll:
  175. permission: *
  176. permission message: &cDu har ikke adgang til dette.
  177. trigger:
  178. if (size of {roulette::*}) is greater or equal to 1:
  179. set {_reel1} to a random integer between 0 and 100
  180. set {roulette.igang} to true
  181. if {_reel1} is between 0 and 48:
  182. loop 10 times:
  183. add 1 to {_resut1}
  184. delete {_rew}
  185. chance of 10%:
  186. set {_rew} to true
  187. set block at {roll.location::1} to red stained clay
  188. set block at {roll.location::2} to black stained clay
  189. set block at {roll.location::3} to red stained clay
  190. set block at {roll.location::4} to black stained clay
  191. set block at {roll.location::5} to red stained clay
  192. wait 10 ticks
  193. if {_rew} is true:
  194. set block at {roll.location::1} to green stained clay
  195. else:
  196. set block at {roll.location::1} to black stained clay
  197. set block at {roll.location::2} to red stained clay
  198. set block at {roll.location::3} to black stained clay
  199. set block at {roll.location::4} to red stained clay
  200. set block at {roll.location::5} to black stained clay
  201. wait 10 ticks
  202. set block at {roll.location::1} to red stained clay
  203. if {_rew} is true:
  204. set block at {roll.location::2} to green stained clay
  205. else:
  206. set block at {roll.location::2} to black stained clay
  207. set block at {roll.location::3} to red stained clay
  208. set block at {roll.location::4} to black stained clay
  209. set block at {roll.location::5} to red stained clay
  210. wait 10 ticks
  211. set block at {roll.location::1} to black stained clay
  212. set block at {roll.location::2} to red stained clay
  213. if {_rew} is true:
  214. set block at {roll.location::3} to green stained clay
  215. else:
  216. set block at {roll.location::3} to black stained clay
  217. set block at {roll.location::4} to red stained clay
  218. set block at {roll.location::5} to black stained clay
  219. wait 10 ticks
  220. set block at {roll.location::1} to red stained clay
  221. set block at {roll.location::2} to black stained clay
  222. set block at {roll.location::3} to red stained clay
  223. if {_rew} is true:
  224. set block at {roll.location::4} to green stained clay
  225. else:
  226. set block at {roll.location::4} to black stained clay
  227. set block at {roll.location::5} to red stained clay
  228. wait 10 ticks
  229. set block at {roll.location::1} to black stained clay
  230. set block at {roll.location::2} to red stained clay
  231. set block at {roll.location::3} to black stained clay
  232. set block at {roll.location::4} to red stained clay
  233. if {_rew} is true:
  234. set block at {roll.location::5} to green stained clay
  235. else:
  236. set block at {roll.location::5} to black stained clay
  237. wait 10 ticks
  238. if {_resut1} is 10:
  239. if block at {roll.location::3} is black stained clay:
  240. loop all players:
  241. if {roulette::%{uuid::%loop-player%}%} is true:
  242. if {sort.roulette::%{uuid::%loop-player%}%} is true:
  243. add {penge.roulette::%{uuid::%loop-player%}%} to loop-player's balance
  244. add {penge.roulette::%{uuid::%loop-player%}%} to loop-player's balance
  245. send "&8[&4Casino&8] &7Du vandt dit bet på &8Sort&7 og fik &a$%{penge.roulette::%{uuid::%loop-player%}%} * 2%&7 ud af det"
  246. delete {roulette::%uuid of loop-player%}
  247. delete {penge.roulette::%{uuid::%loop-player%}%}
  248. else:
  249. send "&8[&4Casino&8] &7Du tabte dit bet på &a$%{penge.roulette::%{uuid::%loop-player%}%}%"
  250. delete {roulette::%uuid of loop-player%}
  251. delete {penge.roulette::%{uuid::%loop-player%}%}
  252. delete {roulette.igang}
  253. stop
  254. if {_reel1} is between 49 and 95:
  255. loop 10 times:
  256. add 1 to {_resut2}
  257. delete {_rew}
  258. chance of 10%:
  259. set {_rew} to true
  260. set block at {roll.location::1} to black stained clay
  261. set block at {roll.location::2} to red stained clay
  262. set block at {roll.location::3} to black stained clay
  263. set block at {roll.location::4} to red stained clay
  264. set block at {roll.location::5} to black stained clay
  265. wait 10 ticks
  266. if {_rew} is true:
  267. set block at {roll.location::1} to green stained clay
  268. else:
  269. set block at {roll.location::1} to red stained clay
  270. set block at {roll.location::2} to black stained clay
  271. set block at {roll.location::3} to red stained clay
  272. set block at {roll.location::4} to black stained clay
  273. set block at {roll.location::5} to red stained clay
  274. wait 10 ticks
  275. set block at {roll.location::1} to black stained clay
  276. if {_rew} is true:
  277. set block at {roll.location::2} to green stained clay
  278. else:
  279. set block at {roll.location::2} to red stained clay
  280. set block at {roll.location::3} to black stained clay
  281. set block at {roll.location::4} to red stained clay
  282. set block at {roll.location::5} to black stained clay
  283. wait 10 ticks
  284. set block at {roll.location::1} to red stained clay
  285. set block at {roll.location::2} to black stained clay
  286. if {_rew} is true:
  287. set block at {roll.location::3} to green stained clay
  288. else:
  289. set block at {roll.location::3} to red stained clay
  290. set block at {roll.location::4} to black stained clay
  291. set block at {roll.location::5} to red stained clay
  292. wait 10 ticks
  293. set block at {roll.location::1} to black stained clay
  294. set block at {roll.location::2} to red stained clay
  295. set block at {roll.location::3} to black stained clay
  296. if {_rew} is true:
  297. set block at {roll.location::4} to green stained clay
  298. else:
  299. set block at {roll.location::4} to red stained clay
  300. set block at {roll.location::5} to black stained clay
  301. wait 10 ticks
  302. set block at {roll.location::1} to red stained clay
  303. set block at {roll.location::2} to black stained clay
  304. set block at {roll.location::3} to red stained clay
  305. set block at {roll.location::4} to black stained clay
  306. if {_rew} is true:
  307. set block at {roll.location::5} to green stained clay
  308. else:
  309. set block at {roll.location::5} to red stained clay
  310. wait 10 ticks
  311. if {_resut2} is 10:
  312. if block at {roll.location::3} is red stained clay:
  313. loop all players:
  314. if {roulette::%{uuid::%loop-player%}%} is true:
  315. if {rød.roulette::%{uuid::%loop-player%}%} is true:
  316. add {penge.roulette::%{uuid::%loop-player%}%} to loop-player's balance
  317. add {penge.roulette::%{uuid::%loop-player%}%} to loop-player's balance
  318. send "&8[&4Casino&8] &7Du vandt dit bet på &cRød&7 og fik &a$%{penge.roulette::%{uuid::%loop-player%}%} * 2%&7 ud af det"
  319. delete {roulette::%uuid of loop-player%}
  320. delete {penge.roulette::%{uuid::%loop-player%}%}
  321. else:
  322. send "&8[&4Casino&8] &7Du tabte dit bet på &a$%{penge.roulette::%{uuid::%loop-player%}%}%"
  323. delete {roulette::%uuid of loop-player%}
  324. delete {penge.roulette::%{uuid::%loop-player%}%}
  325. delete {roulette.igang}
  326. stop
  327. else:
  328. loop 10 times:
  329. add 1 to {_resut3}
  330. set block at {roll.location::1} to red stained clay
  331. set block at {roll.location::2} to black stained clay
  332. set block at {roll.location::3} to red stained clay
  333. set block at {roll.location::4} to black stained clay
  334. set block at {roll.location::5} to red stained clay
  335. wait 10 ticks
  336. if {_resut3} is 10:
  337. set block at {roll.location::1} to black stained clay
  338. set block at {roll.location::2} to red stained clay
  339. set block at {roll.location::3} to black stained clay
  340. set block at {roll.location::4} to red stained clay
  341. set block at {roll.location::5} to black stained clay
  342. wait 10 ticks
  343. set block at {roll.location::1} to red stained clay
  344. set block at {roll.location::2} to black stained clay
  345. set block at {roll.location::3} to red stained clay
  346. set block at {roll.location::4} to black stained clay
  347. set block at {roll.location::5} to red stained clay
  348. wait 10 ticks
  349. set block at {roll.location::1} to green stained clay
  350. set block at {roll.location::2} to red stained clay
  351. set block at {roll.location::3} to black stained clay
  352. set block at {roll.location::4} to red stained clay
  353. set block at {roll.location::5} to black stained clay
  354. wait 10 ticks
  355. set block at {roll.location::1} to red stained clay
  356. set block at {roll.location::2} to green stained clay
  357. set block at {roll.location::3} to red stained clay
  358. set block at {roll.location::4} to black stained clay
  359. set block at {roll.location::5} to red stained clay
  360. wait 10 ticks
  361. set block at {roll.location::1} to black stained clay
  362. set block at {roll.location::2} to red stained clay
  363. set block at {roll.location::3} to green stained clay
  364. set block at {roll.location::4} to red stained clay
  365. set block at {roll.location::5} to black stained clay
  366. else:
  367. set block at {roll.location::1} to black stained clay
  368. set block at {roll.location::2} to red stained clay
  369. set block at {roll.location::3} to black stained clay
  370. set block at {roll.location::4} to red stained clay
  371. set block at {roll.location::5} to black stained clay
  372. wait 10 ticks
  373. set block at {roll.location::1} to red stained clay
  374. set block at {roll.location::2} to black stained clay
  375. set block at {roll.location::3} to red stained clay
  376. set block at {roll.location::4} to black stained clay
  377. set block at {roll.location::5} to red stained clay
  378. wait 10 ticks
  379. set block at {roll.location::1} to black stained clay
  380. set block at {roll.location::2} to red stained clay
  381. set block at {roll.location::3} to black stained clay
  382. set block at {roll.location::4} to red stained clay
  383. set block at {roll.location::5} to black stained clay
  384. wait 10 ticks
  385. set block at {roll.location::1} to red stained clay
  386. set block at {roll.location::2} to black stained clay
  387. set block at {roll.location::3} to red stained clay
  388. set block at {roll.location::4} to black stained clay
  389. set block at {roll.location::5} to red stained clay
  390. wait 10 ticks
  391. set block at {roll.location::1} to black stained clay
  392. set block at {roll.location::2} to red stained clay
  393. set block at {roll.location::3} to black stained clay
  394. set block at {roll.location::4} to red stained clay
  395. set block at {roll.location::5} to black stained clay
  396. wait 10 ticks
  397. if {_resut3} is 10:
  398. if block at {roll.location::3} is green stained clay:
  399. loop all players:
  400. if {roulette::%{uuid::%loop-player%}%} is true:
  401. if {grøn.roulette::%{uuid::%loop-player%}%} is true:
  402. loop 10 times:
  403. add {penge.roulette::%{uuid::%loop-player%}%} to loop-player's balance
  404. send "&8[&4Casino&8] &7Du vandt dit bet på &aGrøn&7 og fik &a$%{penge.roulette::%{uuid::%loop-player%}%} * 10%&7 ud af det"
  405. delete {roulette::%uuid of loop-player%}
  406. delete {penge.roulette::%{uuid::%loop-player%}%}
  407. else:
  408. send "&8[&4Casino&8] &7Du tabte dit bet på &a$%{penge.roulette::%{uuid::%loop-player%}%}%"
  409. delete {roulette::%uuid of loop-player%}
  410. delete {penge.roulette::%{uuid::%loop-player%}%}
  411. delete {roulette.igang}
  412. on quit:
  413. delete {penge.roulette::%{uuid::%player%}%}
  414. delete {rød.roulette::%{uuid::%player%}%}
  415. delete {grøn.roulette::%{uuid::%player%}%}
  416. delete {sort.roulette::%{uuid::%player%}%}
  417. delete {roulette::%{uuid::%player%}%}
Advertisement
Add Comment
Please, Sign In to add comment