Need help with skript

  • 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!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Acidic

Member
Feb 12, 2024
10
0
1
23
Hey,

So I was wondering how I can make it so when I right click an observer at a specific location with a piece of paper that has a specific name, it'll teleport you. It has to be that the right clicked observer has to be at a specific location, or else it won't teleport you. Here is what I have so far.
 

Attachments

  • passes.sk
    142 bytes · Views: 17
Last edited:
Hey,

So I was wondering how I can make it so when I right click an observer at a specific location with a piece of paper that has a specific name, it'll teleport you. It has to be that the right clicked observer has to be at a specific location, or else it won't teleport you. Here is what I have so far.
This should be what you're looking for! Click on the spoiler I provided below to see what I wrote & explanations of the line I added in the notes.
Code:
on rightclick on observer:
location of event-block is location(X, Y, Z, player's world) # Put location here, by using 'event-block' we can check certain properties of any block in a given event. This can also be if the event-block is powered, open, etc.
   if player is holding paper named "ᴘᴀѕѕ":
      teleport player to location(9.500, -60.00000, -10.500, world)
 
  • Like
Reactions: Acidic
I encountered some issues while reloading the skript. I tried doing what the errors said, and it successfully reloaded, but the observer at the block I chose did not teleport the player.

Here is the code I have in the skript right now:
Code:
on rightclick on observer:
location of event-block is location(0, -60, 0, world)
   if player is holding paper named "ᴘᴀѕѕ":
      teleport player to location(9.500, -60.00000, -10.500, world)


Here is the initial error message from the skript you sent:
 

Attachments

  • Screenshot 2024-02-12 213648.png
    Screenshot 2024-02-12 213648.png
    149.4 KB · Views: 13