1. 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!

  2. LOOKING FOR A VERSION OF SKRIPT?

    You can always check out our Wiki for downloads and any other information about Skript!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

on click on exact location

Discussion in 'Skript' started by Drakem, Jun 27, 2022.

  1. Drakem

    Drakem Member

    Joined:
    Apr 29, 2022
    Messages:
    10
    Likes Received:
    0
    I cant make this work, please help
    Code (Text):
    1. on rightclick on a trapped chest:
    2.        set {_location} to location of event-block
    3.        message "&3%{_location}%" to console #debug
    4.        if {_location} is location(-124.5, -33.5, 25.5, world "world", -90, -0)
    5. :                 message "&Hello" to player
    event-block location (debug from the console):
    x: -124.5, y: -33.5, z: 25.5, yaw: -90, pitch: -0 in 'world'
     
  2. Crocie

    Crocie Member

    Joined:
    Jul 2, 2021
    Messages:
    36
    Likes Received:
    0
    make sure it's the exact same place

    Code (Text):
    1. on rightclick on a trapped chest:
    2.     set {_loc} to location of event-block
    3.     if "%{_loc}%" = "x: -124.5, y: -33.5, z: 25.5, yaw: -90, pitch: -0 in 'world'":
    4.         send "hey" to player
     

Share This Page

Loading...