My server has a function to reward advancement completion with a random item. The function uses the execute command, but players don't get permission to this command for obvious reasons.
How do I make the function command run through the console for the player?
Assuming you only want to reward the player with random items, you can use as reward loot tables instead of a function. I suggest looking for skylinerw's post on custom advancements and his post on custom loot tables. By far the best you'll find atm. Hope I was helpful :)))
We use our own custom plugin to reward random items based on a set of criteria we determine with custom chances and sub-chances.
Then, you don't need the /execute in your function files(the function is executing by default as the player). If that doesn't work, the only way I can think of is making as a reward a function with only the command gamerule gameLoopFunction namespace:your_function. And in your function, clear the gameLoopFunction.
The goal with this post is to find out a way to make the function run via the console instead of the player.
It seems as if the reward command is being forced to run as the player instead of just running through the console @ the player.
In vanilla minecraft this is not an issue, we cannot help you unless you provide details and/or are willing to change the way you are doing things. If you can't avoid using execute, there is no way to make a player run a command in a way that they are not running it.
In vanilla minecraft this is not an issue, we cannot help you unless you provide details and/or are willing to change the way you are doing things. If you can't avoid using execute, there is no way to make a player run a command in a way that they are not running it.
I don't want the player running the command.
What is happening is when a player gets an advancement, the command is being issued, but it's being forced/sudo issued to run from the player's perspective/permissions.
What should be happening is when the reward command is ran from the advancement, the console should run the command instead. That's not happening at this point and I'd like to know if it is possible.
What is happening is when a player gets an advancement, the command is being issued, but it's being forced/sudo issued to run from the player's perspective/permissions.
What should be happening is when the reward command is ran from the advancement, the console should run the command instead. That's not happening at this point and I'd like to know if it is possible.
That is normal behavior. When you complete an advancement, you run the commands. No way around it.
My server has a function to reward advancement completion with a random item. The function uses the execute command, but players don't get permission to this command for obvious reasons.
How do I make the function command run through the console for the player?
https://geminiservers.net - List your Minecraft server for free!
We use our own custom plugin to reward random items based on a set of criteria we determine with custom chances and sub-chances.
https://geminiservers.net - List your Minecraft server for free!
The goal with this post is to find out a way to make the function run via the console instead of the player.
It seems as if the reward command is being forced to run as the player instead of just running through the console @ the player.
https://geminiservers.net - List your Minecraft server for free!
In vanilla minecraft this is not an issue, we cannot help you unless you provide details and/or are willing to change the way you are doing things. If you can't avoid using execute, there is no way to make a player run a command in a way that they are not running it.
I don't want the player running the command.
What is happening is when a player gets an advancement, the command is being issued, but it's being forced/sudo issued to run from the player's perspective/permissions.
What should be happening is when the reward command is ran from the advancement, the console should run the command instead. That's not happening at this point and I'd like to know if it is possible.
https://geminiservers.net - List your Minecraft server for free!
That is normal behavior. When you complete an advancement, you run the commands. No way around it.
That's all I needed to know. Thank you.
https://geminiservers.net - List your Minecraft server for free!
I'm sorry for this necro. I just wanna let people know that there's a fix made on spigot.
In commands.yml, make unrestricted-advancements: true to have those functions running in console-level.
P.S. I support @MCFUser13750450 's opinion that advancements have impacts dismissed by many people.
I really appreciate his/her effort on trying to correct the heading.