Solved Help plss :)

  • 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.
no work still can drop compass

Do you really set the "name" to the name of the compass that should not be dropable?

If you think you do it right try it without the "name" condition:

code_language.skript:
on drop:
     if player's tool is compass:
         cancel event
 
Do you really set the "name" to the name of the compass that should not be dropable?

If you think you do it right try it without the "name" condition:

code_language.skript:
on drop:
     if player's tool is compass:
         cancel event
i'm not using the compass named. i try without compass named but still can drop
 
So how to explain.. This error is an error of our thinking. So we have this script:

on drop: #If an item is dropped this will called
if player's tool is compass: #So now we would get the type of the dropped item... and bam thats the error! If i drop an item, the item isn't my selected item anymore. So if i have a stack of wood and i will drop one of them, the name of the players tool will be 63 wood... because the one is already away. So whats happens if you drop a compass your player tool will be "0 air" --> So the condition will be false and the action would'nt be canceled. Thats the whole error. :emoji_grinning:

An after this long explanation... Yep theres an solution :emoji_slight_smile: You only have to do this:

code_language.skript:
on drop of compass:
    cancel event
    message "&cNope!" to player
    stop

So I hope this helps and you understand my explanation :emoji_grinning:
 
So how to explain.. This error is an error of our thinking. So we have this script:

on drop: #If an item is dropped this will called
if player's tool is compass: #So now we would get the type of the dropped item... and bam thats the error! If i drop an item, the item isn't my selected item anymore. So if i have a stack of wood and i will drop one of them, the name of the players tool will be 63 wood... because the one is already away. So whats happens if you drop a compass your player tool will be "0 air" --> So the condition will be false and the action would'nt be canceled. Thats the whole error. :emoji_grinning:

An after this long explanation... Yep theres an solution :emoji_slight_smile: You only have to do this:

code_language.skript:
on drop of compass:
    cancel event
    message "&cNope!" to player
    stop

So I hope this helps and you understand my explanation :emoji_grinning:
The stop isn't necessary. It automatically stops if there is no more code in the trigger section.
 
ok tq all. where i can get the Skriptplus / Skript for version 1.11 / 1.11.2. because i have skript author BEnsku and try in version spigot 1.11 / 1.11.2 get error in variables. but i using in 1.8 - 1.10 no error
 
I also uses 1.11.2 spigot and the newest version from Bensku but for me all works fine, maybe other scripts don't work with this? Post your error code here please so that we can help you.
 
25zlf9x.png
9

this is
 


So as i can see als 5 errors are based on script faults that you make while writing this. PS: If you use some functions that you copy from skunity make sure you have the addon. And basicly I think: on drink a water bottle should be on consume of a water bottle

So the format slot of player happen because you need SkQuery.

So test these thing and look how many errors you get then.
 
So as i can see als 5 errors are based on script faults that you make while writing this. PS: If you use some functions that you copy from skunity make sure you have the addon. And basicly I think: on drink a water bottle should be on consume of a water bottle

So the format slot of player happen because you need SkQuery.

So test these thing and look how many errors you get then.
i know man i need skquery and i have... in version spigot 1.8 - 1.10 work. but in 1.11 - 1.11.2 no work can u give me skquery new version ??
and
on consume of a water bottle is not work...
try alone if u no believe ;/
 
i know man i need skquery and i have... in version spigot 1.8 - 1.10 work. but in 1.11 - 1.11.2 no work can u give me skquery new version ??
and
on consume of a water bottle is not work...
try alone if u no believe ;/

Yes i see the error :emoji_slight_smile: Sorry you have to use this syntax:

code_language.skript:
on consume of a water_bottle:
    cancel event

-> you have to replace cancel event with your code.

And the new version of SKQuery you can find here.
 
Yes i see the error :emoji_slight_smile: Sorry you have to use this syntax:

code_language.skript:
on consume of a water_bottle:
    cancel event

-> you have to replace cancel event with your code.

And the new version of SKQuery you can find here.
code_language.skript:
on consume of a water bottle:
    add 5 to {EN.%player%}
    send "seger cuk"
this is my code and still error

and i using that version skquerty still error
 
code_language.skript:
on consume of a water bottle:
    add 5 to {EN.%player%}
    send "seger cuk"
this is my code and still error

and i using that version skquerty still error

Ah year see it :emoji_slight_smile:. not "water bottle" --> "water_bottle", its hard to see in the Skript code :emoji_slight_smile:
 
ok tq for that code fix the on consume.
now about skquery still error. i done replace new version and delete the old folder the skquery
 
So to make some things clear please write the following:

What minecraft version are you using?
How you server startup looks like (upload the file latest.log in you logs directory here in the forum)

That would be great if you can do that :emoji_slight_smile:
 
Status
Not open for further replies.