Head Selling..

  • 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 community!

    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.

Jakkeren

Supporter
Mar 23, 2017
63
3
8
Hi there.
I'm trying to make a skript, where animals drop their skulls, and you are able to sell them. The heads drop, but you aren't able to sell them. When i click on the sign, nothing happens, and the skull does not get removed. I need help as quick as possible, thanks in advance!

http://pastebin.com/6ZRHzSpn
 
Hi there.
I'm trying to make a skript, where animals drop their skulls, and you are able to sell them. The heads drop, but you aren't able to sell them. When i click on the sign, nothing happens, and the skull does not get removed. I need help as quick as possible, thanks in advance!

http://pastebin.com/6ZRHzSpn
You are literally telling skript it should remove a player from you inventory. (... Parsed as offline player)

You can check the name of the item the player is holding (name if player's tool is ...)

So just make the name unique (for example by adding a color code... You had a formating code) and check if the players tool is named so.

Maybe you also have to change the formating code into a color code if it don't works...

code_language.skript:
on rightclick on a sign:
    line 2 of the clicked block is "&2&lSÆLG":
    if player's tool is head named "&rPig":
        remove 1 of head named "&rPig" from player
        # remove player's tool from player's inventory
        make console execute command "/eco give %player% 5
 
You are literally telling skript it should remove a player from you inventory. (... Parsed as offline player)

You can check the name of the item the player is holding (name if player's tool is ...)

So just make the name unique (for example by adding a color code... You had a formating code) and check if the players tool is named so.

Maybe you also have to change the formating code into a color code if it don't works...

code_language.skript:
on rightclick on a sign:
    line 2 of the clicked block is "&2&lSÆLG":
    if player's tool is head named "&rPig":
        remove 1 of head named "&rPig" from player
        # remove player's tool from player's inventory
        make console execute command "/eco give %player% 5

This does not work. Nothing happens when i click on the sign.

EDIT: Alright, it works with normal skulls. Since it has to be the skull of a player, in this case, it's the head of "MHF_Pig". I think, that it might have something to do with the skript, that makes the skulls drop.

http://pastebin.com/XbkEZtM8
 
This does not work. Nothing happens when i click on the sign.

EDIT: Alright, it works with normal skulls. Since it has to be the skull of a player, in this case, it's the head of "MHF_Pig". I think, that it might have something to do with the skript, that makes the skulls drop.

http://pastebin.com/XbkEZtM8
I'll be at home in a few hours :emoji_slight_smile: I can just write the skript and send it to you :emoji_wink:
 
Status
Not open for further replies.