Advertisement
Guest User

Untitled

a guest
Jan 21st, 2020
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 24.19 KB | None | 0 0
  1. on rightclick on a entity:
  2.  
  3. if name of entity is "&a&lJACK&f&lPOT":
  4.  
  5. execute player command "/Jackpot"
  6.  
  7.  
  8.  
  9.  
  10.  
  11. options:
  12.  
  13. LJK: &8&l| &a&lJACK&f&lPOT&8&l |
  14.  
  15.  
  16.  
  17. on load:
  18.  
  19. if folder "plugins/Jackpot" doesn't exists:
  20.  
  21. create folder "plugins/Jackpot"
  22.  
  23. if folder "plugins/Jackpot/Userdata" doesn't exists:
  24.  
  25. create folder "plugins/Jackpot/Userdata"
  26.  
  27.  
  28.  
  29. on join:
  30.  
  31. if file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml}" doesn't exists:
  32.  
  33. create file "/plugins/Jackpot/Userdata/%player% - %uuid of player%.yml"
  34.  
  35. wait 3 ticks
  36.  
  37. wf "Spillernavn: %player%" to "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml"
  38.  
  39. wf "Brugt: 0" to "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml"
  40.  
  41. wf "Vundet: 0" to "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml"
  42.  
  43.  
  44.  
  45. command /jackpot [<text>] [<text>]:
  46.  
  47. aliases: /jp
  48.  
  49. trigger:
  50.  
  51. if arg-1 isn't set:
  52.  
  53. wait 3 tick
  54.  
  55. open chest with 6 rows named "&6&lJackpot Menu" to player
  56.  
  57. wait 1 tick
  58.  
  59.  
  60.  
  61. #==========
  62.  
  63. #Information
  64.  
  65. #==========
  66.  
  67. format slot 0 of player with Nether star named "&6&lInformation" with lore "&eJoin en af følgende jackpots||&eog tilføj et bet. &eHåb for det bedste" to be unstealable
  68.  
  69. format slot 8 of player with Nether star named "&6&lInformation" with lore "&eJoin en af følgende jackpots||&eog tilføj et bet. &eHåb for det bedste" to be unstealable
  70.  
  71. format slot 45 of player with Nether star named "&6&lInformation" with lore "&eJoin en af følgende jackpots||&eog tilføj et bet. &eHåb for det bedste" to be unstealable
  72.  
  73. format slot 53 of player with Nether star named "&6&lInformation" with lore "&eJoin en af følgende jackpots||&eog tilføj et bet. &eHåb for det bedste" to be unstealable
  74.  
  75.  
  76.  
  77. #==========
  78.  
  79. #Stor jackpot
  80.  
  81. #==========
  82.  
  83. format slot 4 of player with Blue glass pane named "" to be unstealable
  84.  
  85. format slot 12 of player with Blue glass pane named "" to be unstealable
  86.  
  87. format slot 13 of player with Diamond named "&9&lSTOR" with lore "&7Tryk her for at||&7komme til stor jackpot" to close then run [execute player command "/jackpot s"]
  88.  
  89. format slot 14 of player with Blue glass pane named "" to be unstealable
  90.  
  91. format slot 22 of player with Blue glass pane named "" to be unstealable
  92.  
  93.  
  94.  
  95. #==========
  96.  
  97. #Medium jackpot
  98.  
  99. #==========
  100.  
  101. format slot 16 of player with Yellow glass pane named "" to be unstealable
  102.  
  103. format slot 24 of player with Yellow glass pane named "" to be unstealable
  104.  
  105. format slot 25 of player with Gold ingot named "&e&lMEDIUM" with lore "&7Tryk her for at||&7komme til medium jackpot" to close then run [execute player command "/jackpot m"]
  106.  
  107. format slot 26 of player with Yellow glass pane named "" to be unstealable
  108.  
  109. format slot 34 of player with Yellow glass pane named "" to be unstealable
  110.  
  111.  
  112.  
  113. #==========
  114.  
  115. #Lille jackpot
  116.  
  117. #==========
  118.  
  119. format slot 10 of player with Gray glass pane named "" to be unstealable
  120.  
  121. format slot 18 of player with Gray glass pane named "" to be unstealable
  122.  
  123. format slot 19 of player with Iron ingot named "&8&lLILLE" with lore "&7Tryk her for at||&7komme til lille jackpot" to close then run [execute player command "/jackpot l"]
  124.  
  125. format slot 20 of player with Gray glass pane named "" to be unstealable
  126.  
  127. format slot 28 of player with Gray glass pane named "" to be unstealable
  128.  
  129.  
  130.  
  131. #==========
  132.  
  133. #Spiller jackpot stats
  134.  
  135. #==========
  136.  
  137. set {brugt::%uuid of player%} to yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml"
  138.  
  139. set {vundet::%uuid of player%} to yaml value "Vundet" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml"
  140.  
  141. format slot 31 of player with Orange glass pane named "" to be unstealable
  142.  
  143. format slot 39 of player with Orange glass pane named "" to be unstealable
  144.  
  145. format slot 40 of player with Skull of player named "&e&l%player%" with lore "&6Penge: &e%player's balance%||&8&m---------------||&6Penge vundet: &e$%{vundet::%uuid of player%}%||&6Penge brugt: &e$%{brugt::%uuid of player%}%||&8&m---------------" to be unstealable
  146.  
  147. format slot 41 of player with Orange glass pane named "" to be unstealable
  148.  
  149. format slot 49 of player with Orange glass pane named "" to be unstealable
  150.  
  151.  
  152.  
  153. #==========
  154.  
  155. #Jackpot - Lille
  156.  
  157. #==========
  158.  
  159. if arg-1 is "l":
  160.  
  161. wait 3 ticks
  162.  
  163. set {_slot} to 0
  164.  
  165. set {_glas1} to 27
  166.  
  167. set {_glas2} to 28
  168.  
  169. open chest with 5 rows named "&8&lLille Jackpot" to player
  170.  
  171. wait 1 tick
  172.  
  173. loop 4 times:
  174.  
  175. wait 1 tick
  176.  
  177. format slot {_glas1} of player with Orange glass pane named "" to be unstealable
  178.  
  179. format slot {_glas2} of player with Yellow glass pane named "" to be unstealable
  180.  
  181. add 2 to {_glas1}
  182.  
  183. add 2 to {_glas2}
  184.  
  185. format slot 35 of player with Orange glass pane named "" to be unstealable
  186.  
  187. format slot 36 of player with Nether star named "&6&lInformation" with lore "&eLille Jackpot||&e&lHeld og lykke" to be unstealable
  188.  
  189. if {lillejackpot.min} is greater or equal to 2:
  190.  
  191. format slot 40 of player with 175:0 named "&6&lTid tilbage" with lore "&6Vinderen bliver fundet om:||&e%{lille.jackpot.min}% min &6& &e%{lille.jackpot.sek}% sek.||&6Vinder for: &e$%{lillebet}%" to close then run [execute player command "/jp l"]
  192.  
  193. else:
  194.  
  195. format slot 40 of player with 175:0 named "&6&lVenter på spillere" with lore "&eDer mangler spillere||&eDer skal være min 2 spillere" to close
  196.  
  197. format slot 44 of player with Nether star named "&6&lInformation" with lore "&eLille Jackpot||&e&lHeld og lykke" to be unstealable
  198.  
  199. format slot 38 of player with Iron ingot named "&6&lBet: 50" with lore "&eTryk her for at bet: $50" to close then run [execute player command "/lillebet 50"]
  200.  
  201. format slot 39 of player with Gold ingot named "&6&lBet: 100" with lore "&eTryk her for at bet: $100" to close then run [execute player command "/lillebet 100"]
  202.  
  203. format slot 41 of player with Diamond named "&6&lBet: 150" with lore "&eTryk her for at bet: $150" to close then run [execute player command "/lillebet 150"]
  204.  
  205. format slot 42 of player with Emerald named "&6&lBet: 200" with lore "&eTryk her for at bet: $200" to close then run [execute player command "/lillebet 200"]
  206.  
  207. loop {lillejackpot::*}:
  208.  
  209. wait 1 tick
  210.  
  211. format slot {_slot} of player with Skull of loop-value named "&6&l%loop-value%" with lore "&6Bet: &e$%{lille.bet.%loop-value%}%" to be unstealable
  212.  
  213. add 1 to {_slot}
  214.  
  215.  
  216.  
  217. #==========
  218.  
  219. #Jackpot - Medium
  220.  
  221. #==========
  222.  
  223. if arg-1 is "m":
  224.  
  225. wait 3 ticks
  226.  
  227. set {_slot} to 0
  228.  
  229. set {_glas1} to 27
  230.  
  231. set {_glas2} to 28
  232.  
  233. open chest with 5 rows named "&e&lMedium Jackpot" to player
  234.  
  235. wait 1 tick
  236.  
  237. loop 4 times:
  238.  
  239. wait 1 tick
  240.  
  241. format slot {_glas1} of player with Orange glass pane named "" to be unstealable
  242.  
  243. format slot {_glas2} of player with Yellow glass pane named "" to be unstealable
  244.  
  245. add 2 to {_glas1}
  246.  
  247. add 2 to {_glas2}
  248.  
  249. format slot 35 of player with Orange glass pane named "" to be unstealable
  250.  
  251. format slot 36 of player with Nether star named "&6&lInformation" with lore "&eMedium Jackpot||&e&lHeld og lykke" to be unstealable
  252.  
  253. if {mediumjackpot.min} is greater or equal to 2:
  254.  
  255. format slot 40 of player with 175:0 named "&6&lTid tilbage" with lore "&6Vinderen bliver fundet om:||&e%{medium.jackpot.min}% min &6& &e%{medium.jackpot.sek}% sek.||&6Vinder for: &e$%{mediumbet}%" to close then run [execute player command "/jp m"]
  256.  
  257. else:
  258.  
  259. format slot 40 of player with 175:0 named "&6&lVenter på spillere" with lore "&eDer mangler spillere||&eDer skal være min 2 spillere" to close
  260.  
  261. format slot 44 of player with Nether star named "&6&lInformation" with lore "&eMedium Jackpot||&e&lHeld og lykke" to be unstealable
  262.  
  263. format slot 38 of player with Iron ingot named "&6&lBet: 300" with lore "&eTryk her for at bet: $300" to close then run [execute player command "/mediumbet 300"]
  264.  
  265. format slot 39 of player with Gold ingot named "&6&lBet: 500" with lore "&eTryk her for at bet: $500" to close then run [execute player command "/mediumbet 500"]
  266.  
  267. format slot 41 of player with Diamond named "&6&lBet: 700" with lore "&eTryk her for at bet: $700" to close then run [execute player command "/mediumbet 700"]
  268.  
  269. format slot 42 of player with Emerald named "&6&lBet: 900" with lore "&eTryk her for at bet: $900" to close then run [execute player command "/mediumbet 900"]
  270.  
  271. loop {mediumjackpot::*}:
  272.  
  273. wait 1 tick
  274.  
  275. format slot {_slot} of player with Skull of loop-value named "&6&l%loop-value%" with lore "&6Bet: &e$%{medium.bet.%loop-value%}%" to be unstealable
  276.  
  277. add 1 to {_slot}
  278.  
  279.  
  280.  
  281. #==========
  282.  
  283. #Jackpot - Stor
  284.  
  285. #==========
  286.  
  287. if arg-1 is "s":
  288.  
  289. wait 3 ticks
  290.  
  291. set {_slot} to 0
  292.  
  293. set {_glas1} to 27
  294.  
  295. set {_glas2} to 28
  296.  
  297. open chest with 5 rows named "&9&lStor Jackpot" to player
  298.  
  299. wait 1 tick
  300.  
  301. loop 4 times:
  302.  
  303. wait 1 tick
  304.  
  305. format slot {_glas1} of player with Orange glass pane named "" to be unstealable
  306.  
  307. format slot {_glas2} of player with Yellow glass pane named "" to be unstealable
  308.  
  309. add 2 to {_glas1}
  310.  
  311. add 2 to {_glas2}
  312.  
  313. format slot 35 of player with Orange glass pane named "" to be unstealable
  314.  
  315. format slot 36 of player with Nether star named "&6&lInformation" with lore "&9Stor Jackpot||&e&lHeld og lykke" to be unstealable
  316.  
  317. if {storjackpot.min} is greater or equal to 2:
  318.  
  319. format slot 40 of player with 175:0 named "&6&lTid tilbage" with lore "&6Vinderen bliver fundet om:||&e%{stor.jackpot.min}% min &6& &e%{stor.jackpot.sek}% sek.||&6Vinder for: &e$%{storbet}%" to close then run [execute player command "/jp s"]
  320.  
  321. else:
  322.  
  323. format slot 40 of player with 175:0 named "&6&lVenter på spillere" with lore "&eDer mangler spillere||&eDer skal være min 2 spillere" to close
  324.  
  325. format slot 44 of player with Nether star named "&6&lInformation" with lore "&9Stor Jackpot||&e&lHeld og lykke" to be unstealable
  326.  
  327. format slot 38 of player with Iron ingot named "&6&lBet: 1000" with lore "&eTryk her for at bet: $1000" to close then run [execute player command "/storbet 1000"]
  328.  
  329. format slot 39 of player with Gold ingot named "&6&lBet: 1500" with lore "&eTryk her for at bet: $1500" to close then run [execute player command "/storbet 1500"]
  330.  
  331. format slot 41 of player with Diamond named "&6&lBet: 2000" with lore "&eTryk her for at bet: $2000" to close then run [execute player command "/storbet 2000"]
  332.  
  333. format slot 42 of player with Emerald named "&6&lBet: 2500" with lore "&eTryk her for at bet: $2500" to close then run [execute player command "/storbet 2500"]
  334.  
  335. loop {storjackpot::*}:
  336.  
  337. wait 1 tick
  338.  
  339. format slot {_slot} of player with Skull of loop-value named "&6&l%loop-value%" with lore "&6Bet: &e$%{stor.bet.%loop-value%}%" to be unstealable
  340.  
  341. add 1 to {_slot}
  342.  
  343.  
  344.  
  345. #==========
  346.  
  347. #Lille bet
  348.  
  349. #==========
  350.  
  351. command /lillebet [<text>]:
  352.  
  353. trigger:
  354.  
  355. if arg-1 is "50":
  356.  
  357. if player's balance is greater or equal to 50:
  358.  
  359. remove 50 from player's balance
  360.  
  361. add 50 to {lillebet}
  362.  
  363. add 50 to {brugt::%uuid of player%}
  364.  
  365. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  366.  
  367. if {lillejk.deltag.%player%} isn't set:
  368.  
  369. add player to {lillejackpot::*}
  370.  
  371. add 1 to {lillejackpot.min}
  372.  
  373. set {lillejk.deltag.%player%} to true
  374.  
  375. add 50 to {lille.bet.%player%}
  376.  
  377. send "{@LJK} &6Du har bettet: &e$50" to player
  378.  
  379. make player execute command "/jp l"
  380.  
  381. stop
  382. else:
  383. send "a"
  384.  
  385. else:
  386.  
  387. send "{@LJK} &6Du har ikke penge nok!" to player
  388.  
  389. stop
  390.  
  391. if arg-1 is "100":
  392.  
  393. if player's balance is greater or equal to 100:
  394.  
  395. remove 100 from player's balance
  396.  
  397. add 100 to {lillebet}
  398.  
  399. add 100 to {brugt::%uuid of player%}
  400.  
  401. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  402.  
  403. if {lillejk.deltag.%player%} isn't set:
  404.  
  405. add player to {lillejackpot::*}
  406.  
  407. add 1 to {lillejackpot.min}
  408.  
  409. set {lillejk.deltag.%player%} to true
  410.  
  411. add 100 to {lille.bet.%player%}
  412.  
  413. send "{@LJK} &6Du har bettet: &e$100" to player
  414.  
  415. make player execute command "/jp l"
  416.  
  417. stop
  418.  
  419. else:
  420.  
  421. send "{@LJK} &6Du har ikke penge nok!" to player
  422.  
  423. stop
  424.  
  425. if arg-1 is "150":
  426.  
  427. if player's balance is greater or equal to 150:
  428.  
  429. remove 150 from player's balance
  430.  
  431. add 150 to {lillebet}
  432.  
  433. add 150 to {brugt::%uuid of player%}
  434.  
  435. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  436.  
  437. if {lillejk.deltag.%player%} isn't set:
  438.  
  439. add player to {lillejackpot::*}
  440.  
  441. add 1 to {lillejackpot.min}
  442.  
  443. set {lillejk.deltag.%player%} to true
  444.  
  445. add 150 to {lille.bet.%player%}
  446.  
  447. send "{@LJK} &6Du har bettet: &e$150" to player
  448.  
  449. make player execute command "/jp l"
  450.  
  451. stop
  452.  
  453. else:
  454.  
  455. send "{@LJK} &6Du har ikke penge nok!" to player
  456.  
  457. stop
  458.  
  459. if arg-1 is "200":
  460.  
  461. if player's balance is greater or equal to 200:
  462.  
  463. remove 200 from player's balance
  464.  
  465. add 200 to {lillebet}
  466.  
  467. add 200 to {brugt::%uuid of player%}
  468.  
  469. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  470.  
  471. if {lillejk.deltag.%player%} isn't set:
  472.  
  473. add player to {lillejackpot::*}
  474.  
  475. add 1 to {lillejackpot.min}
  476.  
  477. set {lillejk.deltag.%player%} to true
  478.  
  479. add 200 to {lille.bet.%player%}
  480.  
  481. send "{@LJK} &6Du har bettet: &e$200" to player
  482.  
  483. make player execute command "/jp l"
  484.  
  485. stop
  486.  
  487. else:
  488.  
  489. send "{@LJK} &6Du har ikke penge nok!" to player
  490.  
  491. stop
  492.  
  493.  
  494.  
  495. #==========
  496.  
  497. #Medium bet
  498.  
  499. #==========
  500.  
  501. command /mediumbet [<text>]:
  502.  
  503. trigger:
  504.  
  505. if arg-1 is "300":
  506.  
  507. if player's balance is greater or equal to 300:
  508.  
  509. remove 300 from player's balance
  510.  
  511. add 300 to {mediumbet}
  512.  
  513. add 300 to {brugt::%uuid of player%}
  514.  
  515. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  516.  
  517. if {mediumjk.deltag.%player%} isn't set:
  518.  
  519. add player to {mediumjackpot::*}
  520.  
  521. add 1 to {mediumjackpot.min}
  522.  
  523. set {mediumjk.deltag.%player%} to true
  524.  
  525. add 300 to {medium.bet.%player%}
  526.  
  527. send "{@LJK} &6Du har bettet: &e$300" to player
  528.  
  529. make player execute command "/jp m"
  530.  
  531. stop
  532.  
  533. else:
  534.  
  535. send "{@LJK} &6Du har ikke penge nok!" to player
  536.  
  537. stop
  538.  
  539. if arg-1 is "500":
  540.  
  541. if player's balance is greater or equal to 500:
  542.  
  543. remove 500 from player's balance
  544.  
  545. add 500 to {mediumbet}
  546.  
  547. add 500 to {brugt::%uuid of player%}
  548.  
  549. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  550.  
  551. if {mediumjk.deltag.%player%} isn't set:
  552.  
  553. add player to {mediumjackpot::*}
  554.  
  555. add 1 to {mediumjackpot.min}
  556.  
  557. set {mediumjk.deltag.%player%} to true
  558.  
  559. add 500 to {medium.bet.%player%}
  560.  
  561. send "{@LJK} &6Du har bettet: &e$500" to player
  562.  
  563. make player execute command "/jp m"
  564.  
  565. stop
  566.  
  567. else:
  568.  
  569. send "{@LJK} &6Du har ikke penge nok!" to player
  570.  
  571. stop
  572.  
  573. if arg-1 is "700":
  574.  
  575. if player's balance is greater or equal to 700:
  576.  
  577. remove 700 from player's balance
  578.  
  579. add 700 to {mediumbet}
  580.  
  581. add 700 to {brugt::%uuid of player%}
  582.  
  583. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  584.  
  585. if {mediumjk.deltag.%player%} isn't set:
  586.  
  587. add player to {mediumjackpot::*}
  588.  
  589. add 1 to {mediumjackpot.min}
  590.  
  591. set {mediumjk.deltag.%player%} to true
  592.  
  593. add 700 to {medium.bet.%player%}
  594.  
  595. send "{@LJK} &6Du har bettet: &e$700" to player
  596.  
  597. make player execute command "/jp m"
  598.  
  599. stop
  600.  
  601. else:
  602.  
  603. send "{@LJK} &6Du har ikke penge nok!" to player
  604.  
  605. stop
  606.  
  607. if arg-1 is "900":
  608.  
  609. if player's balance is greater or equal to 900:
  610.  
  611. remove 900 from player's balance
  612.  
  613. add 900 to {mediumbet}
  614.  
  615. add 900 to {brugt::%uuid of player%}
  616.  
  617. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  618.  
  619. if {mediumjk.deltag.%player%} isn't set:
  620.  
  621. add player to {mediumjackpot::*}
  622.  
  623. add 1 to {mediumjackpot.min}
  624.  
  625. set {mediumjk.deltag.%player%} to true
  626.  
  627. add 900 to {medium.bet.%player%}
  628.  
  629. send "{@LJK} &6Du har bettet: &e$900" to player
  630.  
  631. make player execute command "/jp m"
  632.  
  633. stop
  634.  
  635. else:
  636.  
  637. send "{@LJK} &6Du har ikke penge nok!" to player
  638.  
  639. stop
  640.  
  641.  
  642.  
  643. #==========
  644.  
  645. #Stor bet
  646.  
  647. #==========
  648.  
  649. command /storbet [<text>]:
  650.  
  651. trigger:
  652.  
  653. if arg-1 is "1000":
  654.  
  655. if player's balance is greater or equal to 1000:
  656.  
  657. remove 1000 from player's balance
  658.  
  659. add 1000 to {storbet}
  660.  
  661. add 1000 to {brugt::%uuid of player%}
  662.  
  663. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  664.  
  665. if {storjk.deltag.%player%} isn't set:
  666.  
  667. add player to {storjackpot::*}
  668.  
  669. add 1 to {storjackpot.min}
  670.  
  671. set {storjk.deltag.%player%} to true
  672.  
  673. add 1000 to {stor.bet.%player%}
  674.  
  675. send "{@LJK} &6Du har bettet: &e$1000" to player
  676.  
  677. make player execute command "/jp s"
  678.  
  679. stop
  680.  
  681. else:
  682.  
  683. send "{@LJK} &6Du har ikke penge nok!" to player
  684.  
  685. stop
  686.  
  687. if arg-1 is "1500":
  688.  
  689. if player's balance is greater or equal to 1500:
  690.  
  691. remove 1500 from player's balance
  692.  
  693. add 1500 to {storbet}
  694.  
  695. set {brugt::%uuid of player%} to {brugt::%uuid of player%}+1500
  696.  
  697. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  698.  
  699. if {storjk.deltag.%player%} isn't set:
  700.  
  701. add player to {storjackpot::*}
  702.  
  703. add 1 to {storjackpot.min}
  704.  
  705. set {storjk.deltag.%player%} to true
  706.  
  707. add 1500 to {stor.bet.%player%}
  708.  
  709. send "{@LJK} &6Du har bettet: &e$1500" to player
  710.  
  711. make player execute command "/jp s"
  712.  
  713. stop
  714.  
  715. else:
  716.  
  717. send "{@LJK} &6Du har ikke penge nok!" to player
  718.  
  719. stop
  720.  
  721. if arg-1 is "2000":
  722.  
  723. if player's balance is greater or equal to 2000:
  724.  
  725. remove 2000 from player's balance
  726.  
  727. add 2000 to {storbet}
  728.  
  729. set {brugt::%uuid of player%} to {brugt::%uuid of player%}+2000
  730.  
  731. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  732.  
  733. if {storjk.deltag.%player%} isn't set:
  734.  
  735. add player to {storjackpot::*}
  736.  
  737. add 1 to {storjackpot.min}
  738.  
  739. set {storjk.deltag.%player%} to true
  740.  
  741. add 2000 to {stor.bet.%player%}
  742.  
  743. send "{@LJK} &6Du har bettet: &e$2000" to player
  744.  
  745. make player execute command "/jp s"
  746.  
  747. stop
  748.  
  749. else:
  750.  
  751. send "{@LJK} &6Du har ikke penge nok!" to player
  752.  
  753. stop
  754.  
  755. if arg-1 is "2500":
  756.  
  757. if player's balance is greater or equal to 2500:
  758.  
  759. remove 2500 from player's balance
  760.  
  761. add 2500 to {storbet}
  762.  
  763. set {brugt::%uuid of player%} to {brugt::%uuid of player%}+2500
  764.  
  765. set yaml value "Brugt" from file "plugins/Jackpot/Userdata/%player% - %uuid of player%.yml" to "%{brugt::%uuid of player%}%"
  766.  
  767. if {storjk.deltag.%player%} isn't set:
  768.  
  769. add player to {storjackpot::*}
  770.  
  771. add 1 to {storjackpot.min}
  772.  
  773. set {storjk.deltag.%player%} to true
  774.  
  775. add 2500 to {stor.bet.%player%}
  776.  
  777. send "{@LJK} &6Du har bettet: &e$2500" to player
  778.  
  779. make player execute command "/jp s"
  780.  
  781. stop
  782.  
  783. else:
  784.  
  785. send "{@LJK} &6Du har ikke penge nok!" to player
  786.  
  787. stop
  788.  
  789.  
  790.  
  791. command /jkdebug:
  792.  
  793. permission: *
  794.  
  795. trigger:
  796.  
  797. set {lille.jackpot.sek} to 59
  798.  
  799. set {lille.jackpot.min} to 3
  800.  
  801. loop {lillejackpot::*}:
  802.  
  803. delete {lillejk.deltag.%loop-value%}
  804.  
  805. delete {lille.bet.%loop-value%}
  806.  
  807. loop all players:
  808.  
  809. delete {lillejk.deltag.%loop-player%}
  810.  
  811. delete {lillebet}
  812.  
  813. delete {lillejackpot::*}
  814.  
  815. delete {lillejackpot.min}
  816.  
  817.  
  818.  
  819. every second:
  820.  
  821. #==========
  822.  
  823. #Lille jackpot countdown
  824.  
  825. #==========
  826.  
  827. if {lillejackpot.min} is greater or equal to 2:
  828.  
  829. remove 1 from {lille.jackpot.sek}
  830.  
  831. if {lille.jackpot.sek} is between -9999999 and 0:
  832.  
  833. if {lille.jackpot.min} is between -9999999 and 0:
  834.  
  835. set {lille.jackpot.sek} to 59
  836.  
  837. set {lille.jackpot.min} to 3
  838.  
  839. set {_lillestop} to 1
  840.  
  841. set {_lillevinder} to a random player of {lillejackpot::*}
  842.  
  843. broadcast ""
  844.  
  845. broadcast "&6Vinderen af &8&lLille Jackpot &6var spilleren &e%{_lillevinder}% &6og vandt: &e%{lillebet}%"
  846.  
  847. broadcast ""
  848.  
  849. send "{@LJK} &6Du vandt &8&lLille Jackpot &6på &e$%{lillebet}%" to {_lillevinder}
  850.  
  851. set {_vundet} to {brugt::%{_lillevinder}%} + {lillebet}
  852.  
  853. set yaml value "Vundet" from file "plugins/Jackpot/Userdata/%{_lillevinder}% - %uuid of {_lillevinder}%.yml" to "%{_vundet}%"
  854.  
  855. add {lillebet} to {_lillevinder}'s balance
  856.  
  857. loop {lillejackpot::*}:
  858.  
  859. delete {lillejk.deltag.%loop-value%}
  860.  
  861. delete {lille.bet.%loop-value%}
  862.  
  863. delete {lillebet}
  864.  
  865. delete {lillejackpot::*}
  866.  
  867. delete {lillejackpot.min}
  868.  
  869. if {_lillestop} is 1:
  870.  
  871. stop
  872.  
  873. if {lille.jackpot.sek} is 0:
  874.  
  875. set {lille.jackpot.sek} to 59
  876.  
  877. remove 1 from {lille.jackpot.min}
  878.  
  879.  
  880.  
  881. #==========
  882.  
  883. #Medium jackpot countdown
  884.  
  885. #==========
  886.  
  887. if {mediumjackpot.min} is greater or equal to 2:
  888.  
  889. remove 1 from {medium.jackpot.sek}
  890.  
  891. if {medium.jackpot.sek} is between -9999999 and 0:
  892.  
  893. if {medium.jackpot.min} is between -9999999 and 0:
  894.  
  895. set {medium.jackpot.sek} to 59
  896.  
  897. set {medium.jackpot.min} to 3
  898.  
  899. set {_mediumstop} to 1
  900.  
  901. set {_mediumvinder} to a random player of {mediumjackpot::*}
  902.  
  903. broadcast ""
  904.  
  905. broadcast "&6Vinderen af &e&lMedium Jackpot &6var spilleren &e%{_mediumvinder}% &6og vandt: &e%{mediumbet}%"
  906.  
  907. broadcast ""
  908.  
  909. send "{@LJK} &6Du vandt &e&lMedium Jackpot &6på &e$%{mediumbet}%" to {_mediumvinder}
  910.  
  911. set {_vundet} to {brugt::%{_mediumvinder}%} + {mediumbet}
  912.  
  913. set yaml value "Vundet" from file "plugins/Jackpot/Userdata/%{_mediumvinder}% - %uuid of {_mediumvinder}%.yml" to "%{_vundet}%"
  914.  
  915. add {mediumbet} to {_mediumvinder}'s balance
  916.  
  917. loop {mediumjackpot::*}:
  918.  
  919. delete {mediumjk.deltag.%loop-value%}
  920.  
  921. delete {medium.bet.%loop-value%}
  922.  
  923. delete {mediumbet}
  924.  
  925. delete {mediumjackpot::*}
  926.  
  927. delete {mediumjackpot.min}
  928.  
  929. if {_mediumstop} is 1:
  930.  
  931. stop
  932.  
  933. if {medium.jackpot.sek} is 0:
  934.  
  935. set {medium.jackpot.sek} to 59
  936.  
  937. remove 1 from {medium.jackpot.min}
  938.  
  939.  
  940.  
  941. #==========
  942.  
  943. #Stor jackpot countdown
  944.  
  945. #==========
  946.  
  947. if {storjackpot.min} is greater or equal to 2:
  948.  
  949. remove 1 from {stor.jackpot.sek}
  950.  
  951. if {stor.jackpot.sek} is between -9999999 and 0:
  952.  
  953. if {stor.jackpot.min} is between -9999999 and 0:
  954.  
  955. set {stor.jackpot.sek} to 59
  956.  
  957. set {stor.jackpot.min} to 3
  958.  
  959. set {_storstop} to 1
  960.  
  961. set {_storvinder} to a random player of {storjackpot::*}
  962.  
  963. broadcast ""
  964.  
  965. broadcast "&6Vinderen af &9&lStor Jackpot &6var spilleren &e%{_storvinder}% &6og vandt: &e%{storbet}%"
  966.  
  967. broadcast ""
  968.  
  969. send "{@LJK} &6Du vandt &9&lJtor Jackpot &6på &e$%{storbet}%" to {_storvinder}
  970.  
  971. set {_vundet} to {brugt::%{_storvinder}%} + {lillebet}
  972.  
  973. set yaml value "Vundet" from file "plugins/Jackpot/Userdata/%{_storvinder}% - %uuid of {_storvinder}%.yml" to "%{_vundet}%"
  974.  
  975. add {storbet} to {_storvinder}'s balance
  976.  
  977. loop {storjackpot::*}:
  978.  
  979. delete {storjk.deltag.%loop-value%}
  980.  
  981. delete {stor.bet.%loop-value%}
  982.  
  983. delete {storbet}
  984.  
  985. delete {storjackpot::*}
  986.  
  987. delete {storjackpot.min}
  988.  
  989. if {_storstop} is 1:
  990.  
  991. stop
  992.  
  993. if {stor.jackpot.sek} is 0:
  994.  
  995. set {stor.jackpot.sek} to 59
  996.  
  997. remove 1 from {stor.jackpot.min}
  998.  
  999.  
  1000.  
  1001. command /test [<text>]:
  1002.  
  1003. permission: *
  1004.  
  1005. trigger:
  1006.  
  1007. if arg-1 is "l":
  1008.  
  1009. set {lille.jackpot.sek} to 10
  1010.  
  1011. set {lille.jackpot.min} to 0
  1012.  
  1013. if arg-1 is "m":
  1014.  
  1015. set {medium.jackpot.sek} to 10
  1016.  
  1017. set {medium.jackpot.min} to 0
  1018.  
  1019. if arg-1 is "s":
  1020.  
  1021. set {stor.jackpot.sek} to 10
  1022.  
  1023. set {stor.jackpot.min} to 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement