-
-
Notifications
You must be signed in to change notification settings - Fork 374
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New Feature: expression to get block face from block interact event #67
Comments
Not one to do a -bump- normally, but any chance on getting this feature in one of the next releases when you get a chance? Would be very useful for doing directional things related to blocks, and should be fairly straightforward given the methods within the API for interact events (described in the first post). |
Adding new data types is always major testing task, but I'll take look at that when I next have chance to add new features. Intentory clicks, for example, vere bugged for few months until I in dev20 finally managed to fix last of those bugs. |
I understand. Whenever you do get a chance, I'll be open to do a lot of testing with it for you and tell you how it seems to work. I imagine the most useful implementation would be the clicked block face representing a Skript direction. That way you could so stuff like |
Just bumping this to see when this will be a thing, I know you don't have the time to do it and it might be a bigger task then what I thought, I'm bumping this just if you forgot about it and see if you think on add this on a non-far future. |
I will decompile Skript and add this type right now. Then do some testing to see how it goes. Block Face would be nice. Skript tracks all block faces in the block state of blocks. But not for events like player interact. Edit: I will try sometime. Skript and Git are being a bitch right now ;-; |
You know, Github (and Github desktop) is a thing |
The PlayerInteractEvent on Spigot has a method called getBlockFace() which returns a BlockFace representing the side of the block that was clicked. It would be cool if, within the block left/right events in Skript, we could use %clicked block face% and %clicked block opposite face% to get the face that was clicked and the face opposite the one that was clicked as strings. You get the string of block face from the interact event (
e
being interact event) withe.getBlockFace().toString()
and the opposite withe.getBlockFace().getOppositeFace().toString()
.The text was updated successfully, but these errors were encountered: