Search results

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  1. A

    Choose the variable that holds the largest value

    Hi! So let's say I have these three variables set {k} to 5 set {i} to 1 set {n} to 3 How would I tell skript to find which one of the three holds the biggest value? this would be helpful for voting systems, so whenever a player votes at an option, 1 is added to a variable, then skript would...
  2. A

    Solved Spawning item frames?

    Thanks! Works flawlessly!
  3. A

    Solved Spawning item frames?

    No errors, but nothing happens. Still haven't found any solution. I'm also open to suggestions of any skript addons that could possibly do this. Another idea I had was to get the X Y Z coordinates of the clicked block and execute a console command spawning an item frame at the block with...
  4. A

    Solved Spawning item frames?

    Hi! I'm trying to automatically place item frames on blocks by clicking on them with a specific item. I can't find any method to do it though. on right click on leaves: if player's tool is diamond hoe: #how do I spawn the item frame? I tried stuff like spawn item frame on clicked...
  5. A

    Spectators edit GUIs?

    It's SkQuery
  6. A

    Spectators edit GUIs?

    on right click on entity: if name of clicked entity is "gui": set {_gui} to a new chest inventory with 6 row with name "GUI" set slot 40 of {_gui} to unbreakable diamond pickaxe named "&fClick" open {_gui} to player on inventory click: name of clicked item is...
  7. A

    Spectators edit GUIs?

    Hello. It seems that the on inventory click event is not called when a spectator clicks a slot in a GUI. I assume this is because spectators can't move items in chests in vanilla Minecraft. Is there any workaround for this that I could use? I still haven't found a solution. I'm using the newest...
  8. A

    Solved GUI Slots with variables

    "with damage 33" means that the durability is decreased by 33, it's not the same as it having sharpness 33, and that syntax is correct. The rest of the code remains the same, and still doesn't work because the issue is the pickaxe doesn't appear at all, not it having wrong parameters. Are you...
  9. A

    Solved GUI Slots with variables

    Hello, I have the following code: on right click on entity: if name of clicked entity is "gui": set {_gui} to a new chest inventory with 6 row with name "*" set {_numbers::*} to "45", "46", "47", "48", "49", "50", "51", "52" and "53" set {_switch} to random...
  10. A

    Solved Teleport many players around a location

    Oh, you're right, I misread that. Thanks for the help!
  11. A

    Solved Teleport many players around a location

    However, this will teleport all the players to one random block in the radius. I was trying to have each player teleported to a random block in that radius, so in the end the players would be scattered around the location.
  12. A

    Solved Teleport many players around a location

    Hello, How can I teleport all the players on the server to random blocks in a specific radius from a location? I tried a few times and looked at the docs but couldn't find an answer.
  13. A

    Help with the execute command

    I tried your suggestions. The reason I want the projectile to execute a command is because the skript syntax lacks some features that are present in the commands. Example: If I want to play a sound at the projectile: on projectile hit: play sound "block.anvil.land" with volume 1 and pitch...
  14. A

    Help with the execute command

    @Piggydoe I know the console could run it, but that's a specific case. If we could run a command as the projectile, we could use commands with relative coordinates, such as: playing a sound at the projectile, spawning an entity at the projectile, setting a block, playing any particle effect at...
  15. A

    Help with the execute command

    @Piggydoe "on projectile hit" is called when a projectile hits a block, so we can't substitute it with "on damage" Edit: And what I'm trying to do, in short, is execute a command as the projectile, when it hits.
  16. A

    Help with the execute command

    Thanks for the answer. I'm new to the new command syntax (after 1.13) so maybe I'm missing something. Before 1.13 any entity could execute a command. For example "/execute @e[type=arrow,name=some_name] ~ ~ ~ time set night" So I hope there is a command that can execute a command as an arrow. I...
  17. A

    Help with the execute command

    So is there any way to make the command target the actual arrow instead of a player named 'arrow'? Still looking for a solution to this problem
  18. A

    Help with the execute command

    But what if it's gonna be a different command? The problem is that the console doesn't execute any commands as the event-projectile. I don't want a workaround that's gonna work only in this particular example. This is a crucial feature and it needs a real solution.
  19. A

    Help with the execute command

    Hello, I have the following code: on projectile hit: if projectile is an arrow: execute console command "/execute as %event-projectile% run time set night" Doesn't work, doesn't print any errors. Using 2.5-alpha5 with Spigot 1.16.1 Is it because of the alpha release? Any ideas?
  20. A

    Solved Adding items to minecart chest

    Sorry, I don't get it, can you explain further? What am I supposed to put in #stuff ? I decided to change the idea a little bit, instead of using an armor stand I'm gonna use a minecart chest. It has an inventory so I thought it'd be easier. on right click on minecart: add 1 stick to the...