I want to let the Block in the GUI rotate and this would be my solution but I think, its very inefficient to do:
1. double so much code in the richblocks even though only the type of item changes
2. loop all players every 2 seconds
Do you have any solution to do this more efficient?
1. double so much code in the richblocks even though only the type of item changes
2. loop all players every 2 seconds
Code:
options:
richblocks: diamond block with name "&l&5open Crates!" with lore "&fYou own: %{crates.number.%loop-player%}%", emerald block with name "&l&5open Crates!" with lore "&fYou own: %{crates.number.%loop-player%}%" and gold block with name "&l&5open Crates!" with lore "&fYou own: %{crates.number.%loop-player%}%"
# . . . creating the GUI . . .
every 2 seconds:
loop all players:
if name of loop-player's current inventory is "&eC&dR&aA&bT&cE&3S":
set slot 2 of loop-player's current inventory to random element of {@richblocks}