Help me with this

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

stxftb

Member
Jan 17, 2022
1
0
1
24
Hi i wnat to make that when someone crafts for the first time an anvil to get one special item and when they craft it the second time to not get anything i used this skript

variables:
{_times} = "0"


on craft:
if event-item is anvil:
if {_times} is "1":
send ""
if {_times} is "0":
set {_times} to "1"
give player 1 amethyst shard named "&6&lFirst Join" with lore "&fAcesta este un badge [&7COMUN&f], pentru mai multe informati scrie /badge"
 
First of all, you need to *tab* in each line after the "on craft:".

Second, you must use an player instanced version of the variable. Replace each case of "{_times}" with "{%player%.times}"

Thirdly, I would use boolean variables instead of the numbers one and zero in the original variable. Replace "if {_times is} 1" with "if {_times} is true", and do the same for the second case.

Also, I would suggest using a more descriptive name for each variable such as "{%player%.joinitemclaimed}" to help you out when you go over your code later!
 
Status
Not open for further replies.