Why am i getting these errors?

  • 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.
Feb 25, 2017
21
1
0
23
code_language.skript:
#   
#                            W E L C O M E   T O   
#
#                                  MOBCOINS
#
#                C R E A T E D   B Y :   EXPLOSIVE
#
#    (! Please don't edit the settings below unless you know what you are doing !)
Options:
    
#Name of the GUI that opens when the command is run.
  GUIName: <cyan><bold>MobCoins
#Message sent when a player tries to view the plugin list.
  pluginMessage: <lime>I'm sorry, we protect our plug-ins from being shown for safety purposes. For more information on plug-ins, contact the owner or any administrators.
#Message sent when a player tries to use a disabled bukkit command.
  bukkitMessage: <lime>I'm sorry, we protect our bukkit commands for safety purposes. For more information on bukkit commands, contact the owner or any administrators.

  P: &8&m---*---&8(&f&l!&8) &b&lMobCoins &8(&f&l!&8)&8&m---*---
  UP: &8&m---*---&8(&f&l!&8)&8&m---------&8(&f&l!&8)&8&m---*---
  Perm: coins.permission

#End of configuration!


variables:
    {coins.%player%} = 0
    
command /coins [<text>] [<player>] [<number>]:
    trigger:
        if arg 1 is not set:
            send "{@P}"
            send "&7&oYour coins balance is:"
            send ""
            send "&bCoins &3» &f%{coins.%player%}%"
        if arg 1 is "help":
            if player has permission "{@Perm}":
                send "{@P}"
                send "&7&oHere you can view the commands!"
                send ""
                send "&b/coins give (player) (number)"
                send "&b/coins view (player)"
                send "&b/coins remove (player) (number)"
                send "&b/coins reset (player)"
                send "&b/coins shop"
                send "&b/coins transfer"               
                send "{@UP}"               
        if arg 1 is "give":
            if player has permission "{@Perm}":
                send "{@P}"
                send "&7&oPlease give an &aIGN &7and a &aNumber!"
                send ""
                send "{@UP}"
            if arg 2 is set:   
                if player has permission "{@Perm}":
                    send "{@P}"
                    send "&7&oPlease give a &anumber!"
                    send ""
                    send "{@UP}"   
                if arg 3 is set:
                    if player has permission "{@Perm}":
                        add number arg to {coins.%arg-2%}
                        send "{@P}"
                        send "&7&oSuccess you have given a player coins!"
                        send ""
                        send "&a%arg-2% &7has been given &a%number arg%"
                        send "{@UP}"                   
                        send "{@P}" to arg-2
                        send "&7&oYou have been given coins" to arg-2
                        send "" to arg-2
                        send "&a%player% &7has given you &a%number arg% &7coins" to arg-2
                        send "{@UP}" to arg-2                       
            if player does not have permission "{@Perm}":
                send "&8(&c&l!&8)  &cYou don't have permission to run this command."
        if arg 1 is "view":
            send "{@P}"
            send "&7&oPlease give a &aname!"
            send ""
            send "{@UP}"
            if arg 2 is set:
                send "{@P}"
                send "&7&oHere you can see &a%arg-2% &7coins"
                send ""
                send "&bCoins &3» &f%{coins.%arg-2%}%"
        if arg 1 is "remove":
            if player has permission "{@Perm}":
                send "{@P}"
                send "&7&oPlease give an &aIGN &7and a &aNumber!"
                send ""
                send "{@UP}"               
            if arg 2 is set:   
                if player has permission "{@Perm}":
                    send "{@P}"
                    send "&7&oPlease give a &anumber!"
                    send ""
                    send "{@UP}"
                if arg 3 is set:
                    if player has permission "{@Perm}":
                        remove number arg from {coins.%arg-2%}
                        send "{@P}"
                        send "&7&oSuccess you have removed coins from a player!"
                        send ""
                        send "&a%arg-2% &7has lost &a%number arg%"
                        send "{@UP}"                   
                        send "{@P}" to arg-2
                        send "&7&oCoins have been taken from your account!" to arg-2
                        send "" to arg-2
                        send "&a%player% &7has taken &a%number arg% &7coins. &7Your balance is now &a%{coins.%arg-2%}%" to arg-2
                        send "{@UP}" to arg-2                       
            if player does not have permission "{@Perm}":
                send "&8(&c&l!&8)  &cYou don't have permission to run this command."   
        if arg 1 is "reset":       
            if player has permission "{@Perm}":
                send "{@P}"
                send "&7&oPlease give an &aIGN!"
                send ""
                send "{@UP}"
            if arg 2 is set:   
                if player has permission "{@Perm}":
                    send "{@P}"
                    send "&7&oPlease give a &anumber!"
                    send ""
                    send "{@UP}"               
                if arg 3 is set:
                    if player has permission "{@Perm}":
                        set {coins.%arg-2%} to 0
                        send "{@P}"
                        send "&7&oSuccess you have reset a players coin balance!"
                        send ""
                        send "&a%arg-2% &7has had their coins reset!"
                        send "{@UP}"
                        send "{@P}" to arg-2
                        send "&7&oYour coins balance has been reset!" to arg-2
                        send "" to arg-2
                        send "&a%player% &7has reset your balance!" to arg-2
                        send "{@UP}" to arg-2
                    
                    
        if arg 1 is "shop":       
            send "{@P}"
            send "&7&oOpening Shop!"
            send ""
            open chest with 1 row named "{@GUIName}" to player
            wait a tick
            format slot 0 of player with 64 of tnt named "<gold><bold>TnT <gold>- 120mc" to close then run [make player execute command "/tntcoins"]
            format slot 1 of player with 64 of obsidian named "<gold><bold>Obsidian <gold>- 40mc" to close then run [make player execute command "/obsidiancoins"]
            format slot 2 of player with 1 of creeper spawn egg named "<gold><bold>Creeper Egg <gold>- 300mc" to close then run [make player execute command "/creepercoins"]
            format slot 3 of player with 1 of enchanted golden apple named "<gold><bold>Super Golden Apple <gold>- 150mc" to close then run "sendmsg %player% You have purchased a super golden apple! Menu Closed!"
            format slot 4 of player with 1 of hopper named "<gold><bold>Hopper <gold>- 70mc" to close then run "sendmsg %player% You have purchased a hopper! Menu Closed!"
            format slot 5 of player with 1 of book and quill named "<gold><bold>/nick <gold>- 1000mc" to close then run "sendmsg %player% You have purchased /nick! Menu Closed!"
            format slot 6 of player with 1 of steak named "<gold><bold>/feed <gold>- 1500mc" to close then run "sendmsg %player% You have purchased /feed! Menu Closed!"
            format slot 7 of player with 1 of water bottle named "<gold><bold>/nv <gold>- 2000mc" to close then run "sendmsg %player% You have purchased /nv! Menu Closed!"
            format slot 8 of player with 1 of nether star named "<gold><bold>Demi-God Rank <gold>- 10,000mc" to close then run "sendmsg %player% You have purchased demi-god rank! Menu Closed!"           
            send ""
            send "{@UP}"   

        if arg 1 is "transfer":
            set {_mobcoins} to number of sunflower named "<gold>MobCoin" in player's inventory
            add {_mobcoins} to {coins.%player%}
            remove {_mobcoins} of sunflower named "<gold>MobCoin" from player's inventory
            send "&6You just got &c%{_mobcoins}% Coins!"
                

                        
                    
#Send Message Command
command /sendmessage <player> <text>:
  description: Send a message to the specified player.
  usage: /sendmessage <player> <message>
  executable by: console
  aliases: /sendmsg
  trigger:
    send arg 2 to arg 1       

    
    
command /tntcoins:
  permission: "coins.tnt"
  trigger:
    if {coins.%player%} is greater than 120:
      remove 120 from {coins.%player%}
      add 64 tnt to player's inventory

    else:
      send "&6You do not have enough mobcoins, please try again later!"
        
command /obsidiancoins:
  permission: "coins.obsidian"
  trigger:
    if {coins.%player%} is greater than 40:
      remove 40 from {coins.%player%}
      add 64 obsidian to player's inventory

    else:
      send "&6You do not have enough mobcoins, please try again later!"

command /creepercoins:
  permission: "coins.creeper"
  trigger:
    if {coins.%player%} is greater than 300:
      remove 300 from {coins.%player%}
      add 1 creeper spawn egg to player's inventory

    else:
      send "&6You do not have enough mobcoins, please try again later!"
      

on death of zombie:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of creeper:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Blaze:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of CaveSpider:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of enderman:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of SilverFish:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Skeleton:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Slime:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Spider:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Witch:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Wither:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Zombie Pigmen:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim



on death of Chicken:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Cow:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Horse:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Mooshroom:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Ocelot:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Pig:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of sheep:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of SnowGolem:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Squid:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Villager:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim
on death of Wolf:
    if chance of 20%:
        drop 1 sunflower named "<gold>MobCoin" at victim

153584486c1c4587becc50386a34e086.png
 
Status
Not open for further replies.