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

This script is to unififcient but I don't know how to make it shorter?

Discussion in 'Skript' started by stingly, Dec 27, 2021.

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

    stingly New Member

    Joined:
    Jul 27, 2020
    Messages:
    7
    Likes Received:
    0
    When i load this script it just crashes my server

    Code (Text):
    1. command /is [<text>] [<text>]:
    2.     trigger:
    3.         if arg-1 is "create":
    4.             if {lsland.%player%} is not set:
    5.                 add 100 to {pb}
    6.                 set {lsland.%player%} to location({pb}, 30, 0.5, world "bskyblock_world")
    7.                 set block at location({pb}, 30 - 1, 0.5, world "bskyblock_world") to bedrock
    8.                 wait 1 second
    9.                 set blocks between location({pb} - 1, 30 - 1, 0.5 - 1, world "bskyblock_world") and location({pb} - 1, 30 - 1, 0.5 + 4, world "bskyblock_world") to grass block
    10.                 wait 1 second
    11.                 set blocks between location({pb} + 1, 30 - 1, 0.5 - 1, world "bskyblock_world") and location({pb} + 1, 30 - 1, 0.5 + 4, world "bskyblock_world") to grass block
    12.                 wait 1 second
    13.                 set block at location({pb}, 30 - 1, 0.5 - 1, world "bskyblock_world") to grass block
    14.                 wait 1 second
    15.                 set blocks between location({pb} - 1, 30 - 1, 0.5 + 2, world "bskyblock_world") and location({pb} + 4, 30 - 1, 0.5 + 4, world "bskyblock_world") to grass block
    16.                 wait 1 second
    17.                 set blocks between location({pb} - 1, 30 - 2, 0.5 - 1, world "bskyblock_world") and location({pb} + 1, 30 - 2, 0.5 + 4, world "bskyblock_world") to dirt
    18.                 wait 1 second
    19.                 set blocks between location({pb} + 2, 30 - 2, 0.5 + 2, world "bskyblock_world") and location({pb} + 4, 30 - 2, 0.5 + 4, world "bskyblock_world") to dirt
    20.                 wait 1 second
    21.                 set blocks between location({pb} - 1, 30 - 3, 0.5 - 1, world "bskyblock_world") and location({pb} + 1, 30 - 3, 0.5 + 4, world "bskyblock_world") to dirt
    22.                 wait 1 second
    23.                 set blocks between location({pb} + 2, 30 - 3, 0.5 + 2, world "bskyblock_world") and location({pb} + 4, 30 - 3, 0.5 + 4, world "bskyblock_world") to dirt
    24.                 wait 1 second
    25.                 set blocks between location({pb} + 3, 30, 0.5 + 3, world "bskyblock_world") and location({pb} + 3, 30 + 3, 0.5 + 3, world "bskyblock_world") to oak log
    26.                 wait 1 second
    27.                 set blocks between location({pb} + 2, 30 + 3, 0.5 + 2, world "bskyblock_world") and location({pb} + 2, 30 + 3, 0.5 + 4, world "bskyblock_world")
    28.                 wait 1 second
    29.                 set blocks between location({pb} + 2, 30 + 3, 0.5 + 4, world "bskyblock_world") and location({pb} + 4, 30 + 3, 0.5 + 4, world "bskyblock_world")
    30.                 wait 1 second
    31.                 set blocks between location({pb} + 4, 30 + 3, 0.5 + 2, world "bskyblock_world") and location({pb} + 2, 30 + 3, 0.5 + 4, world "bskyblock_world")
    32.                 wait 1 second
    33.                 set block at location({pb} + 3, 30 + 3, 0.5 + 4, world "bskyblock_world")
    34.                 wait 1 second
    35.                 set block at location({pb} + 2, 30 + 3, 0.5 + 5, world "bskyblock_world")
    36.                 wait 1 second
    37.                 set block at location({pb} + 3, 30 + 3, 0.5 + 6, world "bskyblock_world")
    38.                 wait 1 second
    39.                 set block at location({pb} + 3, 30 + 3, 0.5 + 5, world "bskyblock_world")
    40.                 send "&aYou succesfully created your Island"
    41.                 teleport player to {lsland.%player%}
    42.         if arg-1 is "home" or "h":
    43.             if {lsland.%player%} is set:
    44.                 teleport player to {lsland.%player%}
    45.                 send "&aTeleporting to your &eIsland"
    46.             else:
    47.                 send "&cYou don't have a island!"
    48.         if arg-1 is "delete":
    49.             send "&cAre you sure you want to remove your island?" to player
    50.             send "&cType &bYes &cin the chat" to player
    51.             set {removecooldown.%player%} to true
    52.  
    53.  
     
    #1 stingly, Dec 27, 2021
    Last edited: Dec 30, 2021
  2. TheCubPlays

    TheCubPlays Member

    Joined:
    Jun 22, 2021
    Messages:
    42
    Likes Received:
    3
    Hey could you please click the "+" button above your text box and then click the code option and insert your code there with tabs so that its easier to understand..? Also can you send the logs of the server when it crashes?
     
  3. TweedeKamer

    TweedeKamer Member

    Joined:
    Sep 6, 2021
    Messages:
    23
    Likes Received:
    1
    Well you could make it easier by using loops etc but you could just leave it like this.
     
  4. stingly

    stingly New Member

    Joined:
    Jul 27, 2020
    Messages:
    7
    Likes Received:
    0
    But My server crashes if i load this script
     
  5. Embry_

    Embry_ Member

    Joined:
    May 13, 2021
    Messages:
    12
    Likes Received:
    1
    Could you give us error logs for when the server crashes?
     
  6. stingly

    stingly New Member

    Joined:
    Jul 27, 2020
    Messages:
    7
    Likes Received:
    0
Thread Status:
Not open for further replies.

Share This Page

Loading...