Check if player is in water.

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

utol

Member
Feb 10, 2017
17
1
0
25
Tried many codes in this one, but still can't figure it out!

Yes, i've searched for a resource but still no

Here's some attempt codes that i did, that are not working since Water is not a Block.

code_language.skript:
on command:
    If block under player is water:
        cancel event
        message "&cYou cannot execute a command while in &lwater."
 
  • Like
Reactions: Viiral
code_language.skript:
on command:
    If block at player is water:
        cancel event
        message "&cYou cannot execute a command while in &lwater."
This has worked for me in the past. Did not have time to test, though.
 
Tried many codes in this one, but still can't figure it out!

Yes, i've searched for a resource but still no

Here's some attempt codes that i did, that are not working since Water is not a Block.

code_language.skript:
on command:
    If block under player is water:
        cancel event
        message "&cYou cannot execute a command while in &lwater."

It work's.
 
1st of all, if you need a Plugin Request use the correct format, but, if you need Help with a code or if you have a bug post in "Skript" section :/
[doublepost=1488219982,1488219933][/doublepost]
and this code works in skellet:
code_language.skript:
[entity] %entity% (1¦is|2¦is(n't| not)) in water