1. 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!

  2. LOOKING FOR A VERSION OF SKRIPT??:

    You can always check our our Wiki for downloads and any other information about Skript!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

I need help with format slot

Discussion in 'Skript' started by Stefqnutz, Sep 29, 2019.

Thread Status:
Not open for further replies.
  1. Stefqnutz

    Stefqnutz Member

    Joined:
    Sep 23, 2019
    Messages:
    11
    Likes Received:
    0
    command /crafting:
    trigger:
    open chest with 2 rows named "&bCrafting" to player
    wait 1 tick
    if player has 1 Stick:
    if player has 1 Flint:
    format slot 0 of player with arrow named "&cArrow &bCraftable: &aTrue &2Recipes: 1 Stick and 1 Flint"
    else:
    format slot 0 of player with arrow named "&cArrow &bCraftable: &cFalse &2Recipes: 1 Stick and 1 Flint"
    please help!
    it says that "player with arrow is not an item stack"
    what should i do?
     
  2. Ronnoc2w

    Ronnoc2w Member

    Joined:
    Feb 20, 2019
    Messages:
    11
    Likes Received:
    0
    Try to add „to be unstealable“ behind format slot 0 of player with arrow named "&cArrow &bCraftable: &aTrue &2Recipes: 1 Stick and 1 Flint"

    Like this:
    Code (Text):
    1. command /crafting:
    2.  trigger:
    3.   open chest with 2 rows named "&bCrafting" to player
    4.   wait 1 tick
    5.   if player has 1 Stick:
    6.    if player has 1 Flint:
    7.     format slot 0 of player with arrow named "&cArrow &bCraftable: &aTrue &2Recipes: 1 Stick and 1 Flint" to be unstealable
    8.    else:
    9.     format slot 0 of player with arrow named "&cArrow &bCraftable: &cFalse &2Recipes: 1 Stick and 1 Flint" to be unstealable
     
  3. GamingHard

    GamingHard Member

    Joined:
    Oct 5, 2019
    Messages:
    17
    Likes Received:
    0
    Here you go i modified it a little so that it actually crafts an arrow for you. I haven't tested it but it should work

    Code (Text):
    1. command /crafting:
    2.     trigger:
    3.         open chest with 2 rows named "&bCrafting" to player
    4.         wait 1 tick
    5.         if player has 1 Stick:
    6.             if player has 1 Flint:
    7.                 format slot 0 of player with 1 arrow named "&cArrow &bCraftable: &aTrue &2Recipes: 1 Stick and 1 Flint" to close then run [give player 1 arrow]
    8.         else:
    9.             format slot 0 of player with 1 arrow named "&cArrow &bCraftable: &cFalse &2Recipes: 1 Stick and 1 Flint" to close then run [&cYou don't have the required items to craft this!]
    10.  
     
Thread Status:
Not open for further replies.
Loading...