SHARE
TWEET

SHOP FOR MY SERVER

a guest Dec 8th, 2019 102 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #                       set {_a} to 0
  2. #           loop 45 times:
  3. #               format gui slot {_a} of player with gray stained glass pane named " " to do nothing
  4. #               add 1 to {_a}
  5. #           format gui slot 0,4,8,22 and 26 of player with yellow stained glass pane named " " to do nothing
  6. #           format gui slot 18 of player with yellow stained glass pane named "&cBack" to run:
  7. #               player command "/shop blocks"
  8. #_________________________________________________________________________________________________________
  9. options:
  10.     prefix: &a&lVain&2&lFarms&8 |&7
  11.  
  12. function shop(player: player, amount: integer, item: item, cost: number):
  13.     if {_player}'s balance < {_cost}:
  14.         send "{@prefix} You haven't got enough money!" to {_player}
  15.     else:
  16.         remove {_cost} from {_player}'s balance
  17.         give {_player} {_amount} of {_item}
  18.        
  19.        
  20. command /shop [<text>]:
  21.     trigger:
  22.         if arg-1 is "reload" or "rl":
  23.             console command "skript reload Shop.sk"
  24.         if arg-1 is "disable":
  25.             console command "skript disable Shop.sk"
  26.         if arg-1 is not set:
  27.             open virtual chest with size 3 to player
  28.             set {_a} to 0
  29.             loop 45 times:
  30.                 format gui slot {_a} of player with gray stained glass pane named " " to do nothing
  31.                 add 1 to {_a}
  32.             format gui slot 0,2,4,6,8,16,18,20,22,24,26 and 10 of player with green stained glass pane named " " to do nothing
  33.             format gui slot 1,3,5,7,17,19,21,23,25 and 9 of player with lime stained glass pane named " " to do nothing
  34.             format gui slot 11 of player with grass block named "&aBlocks" to run:
  35.                 player command "/shop blocks"
  36.             format gui slot 12 of player with redstone dust named "&cRedstone" to run:
  37.                 player command "/shop redstone"
  38.             format gui slot 13 of player with wheat named "&eFarming" to run:
  39.                 player command "/shop Farming"
  40.             format gui slot 14 of player with iron hoe named "&7Tools" to run:
  41.                 player command "/shop tools"
  42.             format gui slot 15 of player with name tag named "&6Ranks" to run:
  43.                 player command "/shop ranks"
  44.            
  45.  
  46.  
  47.         if arg-1 is "blocks":
  48.             open virtual chest with size 6 to player
  49.             set {_a} to 0
  50.             loop 45 times:
  51.                 format gui slot {_a} of player with gray stained glass pane named " " to do nothing
  52.                 add 1 to {_a}
  53.             format gui slot 0,2,4,6,8,18,26,36, 44, 46, 48, 50, 52 and 10 of player with green stained glass pane named " " to do nothing
  54.             format gui slot 1,3,5,7,17,27,35, 45, 47, 49, 51 and 9 of player with lime stained glass pane named " " to do nothing
  55.             format gui slot 53 of player with barrier named "&cBack" to run:
  56.                 player command "/shop"
  57.             format gui slot 10 of player with 16 grass block named "&7Grass Block &f| &a$120" to run function shop(player, 16, grass block, 120)
  58.             format gui slot 11 of player with 16 sand named "&7Sand &f| &a$220" to run function shop(player, 16, sand, 220)
  59.             format gui slot 12 of player with 16 white concrete named "&7White Concrete &f| &a$320" to run function shop(player, 16, white concrete, 320)
  60.             format gui slot 13 of player with 16 red concrete named "&7Red  Concrete &f| &a$320" to run function shop(player, 16, red concrete, 320)
  61.             format gui slot 14 of player with 16 orange concrete named "&7Orange Concrete &f| &a$320" to run function shop(player, 16, orange concrete, 320)
  62.             format gui slot 15 of player with 16 yellow concrete named "&7Yellow Concrete &f| &a$320" to run function shop(player, 16, yellow concrete, 320)
  63.             format gui slot 16 of player with 16 cyan concrete named "&7Cyan Concrete &f| &a$320" to run function shop(player, 16, cyan concrete, 320)
  64.             format gui slot 19 of player with 16 pink concrete named "&7PinkConcrete &f| &a$320" to run function shop(player, 16, pink concrete, 320)
  65.             format gui slot 20 of player with 16 quartz block named "&7Quartz Block &f| &a$420" to run function shop(player, 16, quartz block concrete, 420)
  66.             format gui slot 21 of player with 16 quartz stairs named "&7Quartz Stairs &f| &a$420" to run function shop(player, 16, quartz stairs concrete, 420)
  67.             format gui slot 22 of player with 16 quartz slab named "&7Quartz Slab &f| &a$420" to run function shop(player, 16, white quartz slab, 420)
  68.             format gui slot 23 of player with 16 white stained glass named "&7White Stained Glass &f| &a$220" to run function shop(player, 16, white stained glass, 220)
  69.             format gui slot 24 of player with 16 red stained glass named "&7Red Stained Glass &f| &a$220" to run function shop(player, 16, red stained glass, 220)
  70.             format gui slot 25 of player with 16 orange stained glass named "&7Orange Stained Glass &f| &a$220" to run function shop(player, 16, orange stained glass, 220)
  71.             format gui slot 28 of player with 16 yellow stained glass named "&7Yellow Stained Glass &f| &a$220" to run function shop(player, 16, yellow stained glass, 220)
  72.             format gui slot 29 of player with 16 lime stained glass named "&7Lime Stained Glass &f| &a$220" to run function shop(player, 16, lime stained glass, 220)
  73.             format gui slot 30 of player with 16 light blue stained glass named "&7Light Blue Stained Glass &f| &a$220" to run function shop(player, 16, light blue stained glass, 220)
  74.             format gui slot 31 of player with 16 white stained glass pane named "&7White Stained Glass Pane &f| &a$220" to run function shop(player, 16, white stained glass pane, 320)
  75.             format gui slot 32 of player with 16 red stained glass pane named "&7Red Stained Glass Pane &f| &a$220" to run function shop(player, 16, red stained glass pane, 320)
  76.             format gui slot 33 of player with 16 orange stained glass pane named "&7Orange Stained Glass Pane &f| &a$220" to run function shop(player, 16, orange glass pane, 320)
  77.             format gui slot 34 of player with 16 yellow stained glass pane named "&7Yellow Stained Glass Pane &f| &a$220" to run function shop(player, 16, yellow glass pane, 320)
  78.             format gui slot 37 of player with 16 lime stained glass pane named "&7Lime Stained Glass Pane &f| &a$220" to run function shop(player, 16, lime stained glass pane, 320)
  79.             format gui slot 38 of player with 16 light blue stained glass pane named "&7Light Blue Stained Glass &f| &a$220" to run function shop(player, 16, light blue glass pane, 320)
  80.             format gui slot 37 of player with 16 oak planks named "&7Oak Planks &f| &a$120" to run function shop(player, 16, oak planks, 120)
  81.             format gui slot 38 of player with 16 birch planks named "&7Birch Planks &f| &a$120" to run function shop(player, 16, birch planks, 120)
  82.             format gui slot 39 of player with 16 spruce planks named "&7Spruce Planks &f| &a$120" to run function shop(player, 16, spruce planks, 120)
  83.             format gui slot 40 of player with 16 dark oak planks named "&7Dark Oak Planks &f| &a$120" to run function shop(player, 16, dark oak planks, 120)
  84.             format gui slot 41 of player with 16 oak logs named "&7Oak Logs &f| &a$150" to run function shop(player, 16, oak logs, 150)
  85.             format gui slot 42 of player with 16 birch logs named "&7Birch Logs &f| &a$150" to run function shop(player, 16, birch logs, 150)
  86.             format gui slot 43 of player with 16 spruce logs named "&7Spruce Logs &f| &a$150" to run function shop(player, 16, spruce logs, 150)
  87.  
  88.  
  89.             #
  90.             #
  91.             #
  92.             #
  93.            
  94.         if arg-1 is "farming":
  95.             open virtual chest with size 3 to player
  96.             set {_a} to 0
  97.             loop 45 times:
  98.                 format gui slot {_a} of player with gray stained glass pane named " " to do nothing
  99.                 add 1 to {_a}
  100.             format gui slot 0,2,4,6,8,18,20,22 and 24 of player with green stained glass pane named " " to do nothing
  101.             format gui slot 1,3,5,7,9,17,19,21,23 and 25 of player with lime stained glass pane named " " to do nothing
  102.             format gui slot 26 of player with barrier named "&cBack" to run:
  103.                 player command "/shop"
  104.             format gui slot 10 of player with 8 wheat seeds named "&7Seeds | &a$200" to run function shop(player, 8, wheat seeds, 200)
  105.             format gui slot 11 of player with 8 carrot named "&7Carrots | &a$2,000" to run function shop(player, 8, carrot, 1000)
  106.             format gui slot 12 of player with 8 potato named "&7Seeds | &a$2,000" to run function shop(player, 8, potato, 1000)
  107.             format gui slot 13 of player with 8 sugar cane named "&7Sugar Cane |&a $1,000" to run function shop(player, 8, sugar cane, 1000)
  108.             format gui slot 14 of player with 8 melon seeds named "&7Melon |&a $10,000" to run function shop(player, 8, melon seeds, 10000)
  109.             format gui slot 15 of player with 8 pumpkin seeds named "&7Pumpkin |&a $20,000" to run function shop(player, 8, pumpkin seeds, 20000)
  110.             format gui slot 16 of player with 16 cactus named "&7Cactus |&a $25,000" to run function shop(player, 16, cactus, 25000)
  111.            
  112.         if arg-1 is "redstone":
  113.             open virtual chest with size 5 to player
  114.             set {_a} to 0
  115.             loop 45 times:
  116.                 format gui slot {_a} of player with gray stained glass pane named " " to do nothing
  117.                 add 1 to {_a}
  118.             format gui slot 0,2,4,6,8,18,20,22,24,26,28,30,32,34,36,38,40 and 42 of player with green stained glass pane named " " to do nothing
  119.             format gui slot 1,3,5,7,9,17,19,21,23,25,27,29,31,33,35,37,39,41 and 43 of player with lime stained glass pane named " " to do nothing
  120.             format gui slot 44 of player with barrier named "&cBack" to run:
  121.                 player command "/shop"
  122.             format gui slot 10 of player with 16 redstone dust named "&8Redstone |&a $600" to run function shop(player, 16, redstone, 600)
  123.             format gui slot 11 of player with 3 hopper named "&8Hopper |&a $25000" to run function shop(player, 3, hopper, 25000)
  124.             format gui slot 12 of player with 5 redstone comparator named "&8Comparator |&a $400" to run function shop(player, 16, redstone comparator, 400)
  125.             format gui slot 13 of player with 16 redstone Repeater named "&8Repeater |&a $400" to run function shop(player, 16, redstone repeater, 400)
  126.             format gui slot 14 of player with 16 string named "&8String |&a $50" to run function shop(player, 16, string, 50)
  127.             format gui slot 15 of player with 4 piston named "&8Piston |&a $500" to run function shop(player, 4, Piston, 500)
  128.             format gui slot 16 of player with 4 sticky piston named "&8Sticky Piston |&a $500" to run function shop(player, 4, sticky Piston, 500)
  129.             format gui slot 19 of player with 2 observer named "&8Observer | &a$500" to run function shop(player, 2, observer, 500)
  130.             format gui slot 20 of player with 16 redstone torch named "&8Torch | &a$50" to run function shop(player, 16, redstone torch, 50)
  131.             format gui slot 21 of player with 16 slime block named "&8Slime Block | &a$5000" to run function shop(player, 16, Slime Block, 5000)
  132.             format gui slot 22 of player with 4 dispenser named "&8Dispenser | &a$500" to run function shop(player, 16, dispenser, 500)
  133.             format gui slot 23 of player with 4 dropper named "&8Dropper | &a$500" to run function shop(player, 16, Dropper, 500)
  134.             format gui slot 24 of player with 4 redstone lamp named "&8Lamp | &a$500" to run function shop(player, 16, redstone Lamp, 500)
  135.            
  136.            
  137.         if arg-1 is "tools":
  138.             open virtual chest with size 4 to player
  139.             set {_a} to 0
  140.             loop 45 times:
  141.                 format gui slot {_a} of player with gray stained glass pane named " " to do nothing
  142.                 add 1 to {_a}
  143.             format gui slot 0,2,4,6,8,12,14,16,18,22,26,28,30,32,34 and 10 of player with green stained glass pane named " " to do nothing
  144.             format gui slot 1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31 and 33 of player with lime stained glass pane named " " to do nothing
  145.             format gui slot 35 of player with barrier named "&cBack" to run:
  146.                 player command "/shop"
  147.             format gui slot 11 of player with diamond pickaxe named "&7 Diamond Pickaxe |&a $500" to run function shop(player, 1, diamond pickaxe, 500)
  148.             format gui slot 20 of player with diamond hoe named "&7 Diamond Hoe |&a $500" to run function shop(player, 1, diamond hoe, 500)
  149.             format gui slot 24 of player with iron hoe named "&7 Iron Hoe |&a $250" to run function shop(player, 1, iron hoe, 250)
  150.             format gui slot 15 of player with iron pickaxe named "&7Iron Pickaxe |&a $250" to run function shop(player, 1, iron pickaxe, 250)
  151.  
  152.         if arg-1 is "ranks":
  153.             send "&c&lComing Soon!"
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top