command /randomcommand:
trigger:
# Define the list of available commands
set {_commands} to ["say 1", "say 2", "say 3", "say 4", "say 5", "say 6", "say 7", "say 8", "say 9", "say 10", "say 11", "say 12", "say 13", "say 14"]
# Check if the player has already used any command
loop
set {_randomIndex} to random integer between 1 and 14
set {_selectedCommand} to {_commands} at {_randomIndex}
if {_selectedCommand} is not set:
continue
else
set {_commands} at {_randomIndex} to null
execute console command "execute as %player% run {_selectedCommand}"
break
trigger:
# Define the list of available commands
set {_commands} to ["say 1", "say 2", "say 3", "say 4", "say 5", "say 6", "say 7", "say 8", "say 9", "say 10", "say 11", "say 12", "say 13", "say 14"]
# Check if the player has already used any command
loop
set {_randomIndex} to random integer between 1 and 14
set {_selectedCommand} to {_commands} at {_randomIndex}
if {_selectedCommand} is not set:
continue
else
set {_commands} at {_randomIndex} to null
execute console command "execute as %player% run {_selectedCommand}"
break