Advertisement
Guest User

Untitled

a guest
Apr 20th, 2019
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CSS 2.26 KB | None | 0 0
  1. command /sell [<text>]:
  2.     trigger:
  3.         if player's inventory doesn't have ores or stone or cobble stone or emerald ore:
  4.             send player title "&6&lSELL" with subtitle "&7Mine blocks then use /sell" for 3 seconds
  5.         if player's inventory has ores or stone or cobble stone or emerald ore:
  6.            play "ui_button_click" to player
  7.            set {_stoneCount} to amount of stone in the player's inventory
  8.             set {_stoneWorth} to 2.2
  9.             remove all stone from player
  10.             set {_coalCount} to amount of coal_ore in the player's inventory
  11.            set {_coalWorth} to 3.5
  12.            remove all coal_ore from player
  13.            set {_ironCount} to amount of iron_ore in the player's inventory
  14.             set {_ironWorth} to 6.3
  15.             remove all iron_ore from player
  16.             set {_goldCount} to amount of gold_ore in the player's inventory
  17.            set {_goldWorth} to 4.6
  18.            remove all gold_ore from player
  19.            set {_diamondCount} to amount of diamond_ore in the player's inventory
  20.             set {_diamondWorth} to 9
  21.             remove all diamond_ore from player
  22.             set {_emeraldCount} to amount of emerald_ore in the player's inventory
  23.            set {_emeraldWorth} to 13
  24.            remove all emerald_ore from player
  25.            set {_cobbleCount} to amount of cobble stone in the player's inventory
  26.             set {_cobbleWorth} to 3.1
  27.             remove all cobble_stone from player
  28.             set {_stoneSell} to {_stoneCount} * {_stoneWorth}
  29.             set {_coalSell} to {_coalCount} * {_coalWorth}
  30.             set {_ironSell} to {_ironCount} * {_ironWorth}
  31.             set {_goldSell} to {_goldCount} * {_goldWorth}
  32.             set {_diamondSell} to {_diamondCount} * {_diamondWorth}
  33.             set {_emeraldSell} to {_emeraldCount} * {_emeraldWorth}
  34.             set {_cobbleSell} to {_cobbleCount} * {_cobbleWorth}
  35.             set {_totalSell} to {_stoneCount} + {_coalCount} + {_ironCount} + {_goldCount} + {_diamondCount} + {_emeraldCount} + {_cobbleCount}
  36.             set {_totalProfit} to {_stoneSell} + {_coalSell} + {_ironSell} + {_goldSell} + {_diamondSell} + {_emeraldSell} + {_cobbleSell}
  37.             set {Coins::%player%} to ({Coins::%player%} + {_totalProfit})
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement