#help with sell

1 messages · Page 1 of 1 (latest)

south harness
#

Assuming the /sell all is trying to look for all items in your inventory that are the same as the one being held, you can check for some identifier like the name of an nbt tag using if equal

#

add up the multiply the amount by value to add to money and then remove all of that item

#
remove all {_x} named {_y} from player's inventory
#

basically

loud fable
#

wht ping me

#

if you only want to sell a certain item

#

check for that

#

or rather a list of items

loud fable
#

you can sell for a price per item

#

or you can make them all worht 1

loud fable
#

could

loud fable
#

yes

somber gazelle
#

Yo the chat is active so I wanna join in

#

Let me read.

#

!format

ivory fractalBOT
# somber gazelle !format

:technologist: Code Blocks

To make it easier for others to read your code, it is asked that you send it in a code block. On Discord, you can simply send this:

```
Code here
```

somber gazelle
#

Make ur custom coin/money system

#

And let it check if the sold item is the custom item. And add it to the player's balance

#

Firstly set the custom items with var.

#

And detect if the player sold items is one of the variables if so sell it with that amount.

#

set {item::name} to pink dye named "blah blah blah"

#

Someone read my messages and explain it to him.

#

Idk. There's some stuff first time I see. Like in line 5

#

I don't have that much skript knowledge but I know how to say it in my way.

ivory fractalBOT
#

:technologist: Code Blocks

To make it easier for others to read your code, it is asked that you send it in a code block. On Discord, you can simply send this:

```
Code here
```

somber gazelle
loud fable
#

"golden nugget" is a string, remove the quotes for it to be an item

loud fable
#

local overload

#

why

#

was this made by chatGPT?

hearty mesa
#

Looks like it

south harness
#

debug to find whats wrong

#

broadcast variables or loop through inventories etc to see if conditions match up

#

@somber gazelle

#

do stuff like broadcast {_amount}

#

see if stuff is getting set

#

maybe names are different

#

or item types are different

#

if its broken it will not return anything or <none>

#

so are you getting a number from broadcast {_amount}

#

broadcast just sends the message in chat

#

so if {_amount = 100 it will send "100" to chat

#

try and see :P

somber gazelle
#

The real crime here is that you be doing this all on mobile