Solved simple skript that should work wont

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

mr_spot

Member
Jul 11, 2022
2
0
1
23
Skript Version: 2.6.2
Skript Addons: SkBee WorldGuard

Skript:
----------------------------------------------------------------
on place of brown candle:
send "&7You May Not Place Your Wand"
cancel event
-----------------------------------------------------------------
when I reload Skript no error is shown in console or in chat
I use the same Skript but instead of brown candle just candle and it works fine so I do not understand why it would not work it sends the message but you can place the candle I am using two other Skripts with brown candle is it posable they are interfering they are
-------------------------------------------------------------------------
on right click holding brown candle :
give dirt to the player
-------------------------------------------------------------------------
and
-------------------------------------------------------------------------
on craft of a brown candle:
cancel event
-------------------------------------------------------------------------
Have you tried searching the docs? yes
Have you tried searching the Forums? no
What other methods have you tried to fix it? I have tried removing the file and re adding it I have tried re writing the Skript but it wont work
[doublepost=1657555916,1657555793][/doublepost]here is Skript I forgot to link it in the thing
[doublepost=1657556168][/doublepost]correction it works it stops you from placing it but it just deletes the candle it doesn't give it back to you like the other exact same Skripts but for different blocks
 

Attachments

  • noplacedirtwand.sk
    81 bytes · Views: 98
Hey there,
Code:
on right click holding brown candle :
    give dirt to the player
    cancel event
add cancel event and it works
 
Hey there,
Code:
on right click holding brown candle :
    give dirt to the player
    cancel event
add cancel event and it works
this works but now the message you can not place wand wont show up
[doublepost=1657721094,1657721003][/doublepost]any ideas
 
this works but now the message you can not place wand wont show up
[doublepost=1657721094,1657721003][/doublepost]any ideas

Hmmmmmm I tried a few things but couldn't make it work so
I just did :
Code:
on place of brown candle:
    cancel event
    give player brown candle
    send "&7You May Not Place Your Wand"

on right click holding brown candle :
    give dirt to the player

on craft of a brown candle:
    cancel event

The problem is if u cancel event in the right click, it does not place it thus not triggering the on place :/
But then if u dont cancel event in right click, it cancel the event of placing it, not the right click or some weird thing like that
So I just thought of giving the brown candle in the place event (so it doesnt multiply by clicking the air!)
I will still try to find a better solution, but that should work just fine
 
Status
Not open for further replies.