Solved Please help me!!

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

Status
Not open for further replies.

LoneDragon38

New Member
Oct 10, 2020
5
0
1
25
Hello, can you guys please fix this simple skript. I cannot cancel potion event. Please help mee

on throw of a potion:
send "No using potion" to player
cancel event

Thank x10000
 
Throwing potions are projectiles just like arrows or snowballs, so you can use `on shoot` event:
Code:
on shoot:
    if projectile is potion:
        send "No using potion" to shooter
        cancel event
 
Code:
on shoot:
    "%projectile%" is "thrown potion":
        send "No using potion" to shooter
        cancel event
This is odd. That's why you should code in Java rather than this.
 
[doublepost=1608638928,1608638557][/doublepost]

Thanks it works perfectly!
This is not supposed to be working:
Code:
on shoot:
    if projectile is thrown potion:
        send "test" to shooter
        cancel event
Line 2: Can't compare a projectile with a visual effect (script.sk, line 2: if projectile is thrown potion:')
 
Status
Not open for further replies.