#Help here xd

1 messages Β· Page 1 of 1 (latest)

summer holly
#

^

dusk summit
#

hi, so the bronze coin helm, is this a replacement for another helmet? since as far as i know you can't create new materials in vanilla. however you can modify existing ones

#

so let's say a "bronze coin helmet" equals an iron helmet but with a different name and maybe some hidden enchantments - totally possible, create a new item - not really unless you're looking for mods

summer holly
#

I just dont know how to make recipes

dusk summit
#

aaaah

#

that's very easily done

#

and the bronze/silver?

summer holly
#

let me rephrase it,
we have a Bronze Head that I want to be craftable, I then want another recipe for 9 Bronze heads turning into 1 Silver head, then the same for more tiers like gold and platinum.

#

so like a gold head would = 9 silver

#

this doesnt seem too hard I just dont know how to make datapacks essentially

dusk summit
#

okay, so here's the issue with the 9 bronze head recipe. as of right now, you can craft with regular items (e.g. player heads) no problem. but, crafting with items with nbt is not possible i believe

summer holly
#

ah I see

#

hmm

dusk summit
#

the output tho is, i can make a bronze coin helmet craftable (it's a bit tricky cuz i'll have to use advancements to make sure the player gets the right item out of the crafting), but it most certainly is possible!

summer holly
#

okay well thats great

dusk summit
#

how would the bronze coin helmet be crafted?

summer holly
#

hmm

dusk summit
#

an alternative for crafting the silver/platinum/etc. helmets is by throwing it on the ground.

By throwing down 9 bronze coin helmet it changes it into a silver coin helmet. but that might be messy in multiplayer

summer holly
#

yeah its only for multiplayer too so I think that wouldnt be as good

summer holly
dusk summit
summer holly
#

what type of link?

dusk summit
#

well the bronze coin helmet is a player head, correct? which one? πŸ™‚

summer holly
#

no I mean like how does one send a player head via a link???

dusk summit
#

ah

#

or if you got a /give command that's fine as well

summer holly
#

oh alright

dusk summit
#

amazing

#

another workaround for crafting next tier items could be to check if the player has 9 bronze coins in his inventory it automatically gets converted to one silver, or if he presses a button with 9 bronze coins it converts to one silver

#

cuz it is possible to check people their inventories for items

summer holly
dusk summit
#

it could go in reverse as well

summer holly
#

but then it would infinitely replace them tho?

#

oh wait heads can stack?

#

is it possible to do a stack of 64 bronze = 1 silver?

#

or is that too difficult

dusk summit
#

how do you mean infinitely?

Here's what I mean:
I can create a datapack that when a player right clicks (air, a block) with 9 bronze coins in his hand it converts those 9 to a silver coin, or if he does that with a silver coin it converts to 9 bronze pieces.

Alternatively I can make datapack that activates this with a button, for example:

summer holly
dusk summit
#

of course!

summer holly
#

epic!

#

(btw, by infinitely I thought you meant if you have a stack of coins it would automatically turn it into the next tier and if you had 1 by itself it would downgrade but I see what you mean now lmao)

#

but that is much nicer

dusk summit
summer holly
#

your idea is much better, (also I couldnt find a platinum head so its Bronze then Silver then Gold then Lilac now)

dusk summit
#

Lilac is a lovely color too xD

summer holly
#

also on top of that could the coins be named:
Bronze Coin
Silver Coin
Gold Coin
Lilac Coin
?

summer holly
dusk summit
#

yeah for sure

#

alright, to get this right: Recipe for bronze coin, with a datapack that checks if a player is right clicking air with a stack of bronze coins to convert it into 1 silver coin (etc. for the others) and when right clicking with one tier coin it converts it into the lower tier stack, correct?

summer holly
#

absolutely

dusk summit
#

cool, gimme a min :p

summer holly
#

ty :]

dusk summit
#

version is 1.19.2?

summer holly
#

mhm

summer holly
dusk summit
#

no worries πŸ™‚ It's not a difficult thing to do once you know how to do it and I know how much it sucks when no one helps :p

summer holly
#

Imma go sleep, pretty late for me

#

ill be back tomorrow tho :]

dusk summit
#

yeah it's 01 am here too xD but I'm in the flow, it'll probably be done by the time you wake up

summer holly
#

You mean 1am? or? It's 0:28 for me in the uk. also by sleep I typically mean watch yt in bed till 2 lmao

#

But yeah gl xd but don't stay up all night lmao

dusk summit
#

lol, nah i'm from the netherlands, we are one hour behind on you

#

Alright, so... issue, I thought I could detect it whenever a player right clicks with a stack of blocks... sadly Minecraft is annoying and this isn't possible, I can however make it automatic, whenever a player has a stack of coins it automatically changes that into one upgraded coin

dusk summit
#

this is part 1 πŸ˜‰ for now i made it automatic (when you're holding a stack, not when you have a stack divided into multiple piles)

#

it only misses the downgrade function right now, I could make a stick for that (since the right click method needs to use a tool to check if you right clicked) and than the player holds the coin he wishes to downgrade in his offhand so the datapack knows which coin to exchange.

Because if I were to make this automatic every time you'd obtain the coin you'd lose it and you'd end up in a never ending cycle of coin conversion :p

#

Note that when crafting the coin it returns a knowledge book instead of a playerhead.
This is because when the item is crafted (when you right click the crafted item), the game recognizes that you unlocked a crafting recipe, which fires an advancement which runs a function.

That function removes the crafted item (because it does not support NBT) and replaces it with the wanted item.
Since the crafted item does not support NBT i won't be able to make this a player head.
I replace the crafted item by first clearing the NBTless item and then giving the NBT item into the inventory.
Say i were to do this with a basic player head, the game would remove the first located player head with /clear, and would thus remove one of the coins and not the crafted item (this is the reason i use a knowledge book)

#

hope this explanation was clear xD It's a whole thing to explain but easy to make

#

Anyways, let me know what you thought of the "downgrade stick" (or other tool), and if this is not to your liking how else we could do the downgrading of coins

summer holly
#

it seems I infinitely get bronze coins and conversion happens even when its not selected in my hotbar, the stick is a good idea tho

#

@dusk summit

#

seems it was a problem with vanilla tweaks "unlock all recipes"

#

which makes sence

#

so thats fixed the infinite bronze coins

#

but not the conversion

summer holly
#

So I think,
if you have 1 silver in ur off hand replace it with a bronze and if you have 64 bronze in your main hand replace it with 1 silver, then it wouldnt need the stick right?

#

also rn it can be anywere in the inv and it will convert no matter on if its in ur hand or not

#

also maybe a way to get the coins quickly with a command for testing
(like:
/Trigger CoinB
/Trigger CoinS
/Trigger CoinG
/Trigger CoinL )

dusk summit
#

Wait, so the bug of infinite conversion is fixed?πŸ˜‚ Didn't follow that at all πŸ˜‚πŸ˜‚

#

I'm at work right now, I'll respons to the rest later 😊

summer holly
#

its not infinitely giving me infinite bronze coins anymore xd

#

was due to the fact I had vanilla tweaks' "unlock all recipes" datapack on too

summer holly
#

Infact here are my ideas:
Change stack amount from 64 to 10 for easier mental math while selling.
Make bronze coins have #AC632E as its hex code instead.
make lilac coins have #B476D3 as its hex code instead.
a /Trigger or /Function command for obtaining coin cheats.
(/Trigger CoinB /Trigger CoinS /Trigger CoinG /Trigger CoinL)
Downgrade coins in offhand only.
Upgrade coins in mainhand only.

#

tell me if any of this is too difficult or is not possible

dusk summit
#

This is very doable πŸ‘πŸ½won't be able to make it until the 16th late or 17th early tho, since I won't be home before that, but the concept is easily doable

summer holly
#

absolutely okay with me

#

gl :]

dusk summit
#

alright managed to sneak in some time for this πŸ™‚

I've stumbled onto a thing, you can check if a player is holding 10 coins, but it'll specifically check for 10 coins, it wont see them if the played is holding 11 coins.
I did fond a work-around that checks for the amount of items in the inventory, but as it says: "in the inventory". This would mean the player no longer has to hold the coins to convert them.

So, I need you to decide between two solutions:

  1. The player does /trigger CoinB and has to hold exactly 10 coins to be able to convert them (but you can decide that this has to be in the first slot).
  2. the player does /trigger CoinB and it'll take 10 coins and give the player 1 silver, regardless of their placement in the inventory (a bit like the automatic one).

This doesn't really impact the downgrading one, since I don't have to specify how many coins are in the offhand and just have to check if there are any coins in the offhand πŸ™‚

#

@summer holly

summer holly
#

if thats possible

dusk summit
#

Wait so the trigger was as some kind of cheat to give yourself a stack of the coins, aha πŸ˜‚ so how did you want the people to convert their coins then ?πŸ€”

summer holly
#

with either, it just being in your main hand or /trigger merge

dusk summit
#

Well that still leaves the problem I described, Minecraft doesn't allow me to check if the player is holding 10 or more items in his hand, however it does allow to check if there's exactly 10 in the main hand. Or alternatively I can check if there are 10 or more in the whole inventory (not in the hand, but in the whole inventory).

So I need you to decide whether you want it so that it check if the player is holding exactly 10 (so it won't work if he's holding 11) or if it checks that there are 10 or more in the whole inventory, which removes the option of it being in the main hand (again, this does not include the downgrade option since the offhand works differently and is way easier to check πŸ™‚ )

dusk summit
#

I'll have time to look at this tomorrow evening, is that okay? and which way of checking would you like me to implement?

#

@summer holly

summer holly
#

Change stack amount from 64 to 10 for easier mental math while selling.
Make bronze coins have #AC632E as its hex code instead.
make lilac coins have #B476D3 as its hex code instead.
a /Trigger command for giving the player 9 coins of a type (and 64 of it if it is /Trigger CoinL).
(/Trigger CoinB /Trigger CoinS /Trigger CoinG /Trigger CoinL)
Downgrade coins in offhand only.
Upgrade all coins in inventory with more than 10 of its type.

#

Updated to do list then ^

dusk summit
#

update time πŸ™‚

Stack amount changed to 10
Bronze and lilac coins have changed into correct hex colours
Downgrade in offhand added
Will do the function cheats soon (I'll make this a function because triggers can be done without /op or any other kind of permission and for /function you do have to be admin).
But. imagine you got 10 bronze coins in your inventory, so it'll automatically upgrade to a silver coin. awesome!
now imagine I put a silver coin in my offhand, it'll replace it into 10 bronze coins.
But what happens if a player has 10 bronze coins? c:

You okay if I make the downgrading automatic but upgrading with a trigger command?

#

@summer holly

summer holly
#

'/Trigger Upgrade' would work fine yeah but change the description of the coin to like "10 of these can be merged into a higher tier with '/Trigger Upgrade'" and then have lilac have like "Highest tier of coin"

#

But this stuff so far is awesome :D

#

@dusk summit

dusk summit
#

awesome! I'll change it right away, think I might be done in like 20 mins if I don't find any other issues

summer holly
#

Alright, can't test it today as of what I know since I don't have access to my pc atm.

#

Oh and also yeah /function for the give coin commands is much better then

dusk summit
#

well... Minecraft is problematic c:
For the downgrading I was using /clear to remove one item and then giving the 10 downgraded items. but turns out /clear starts in the inventory and clears the offhand last, so let's say you got 8 silver coins and one in your offhand, it would take all the 9 silver coins and reward you with 90 bronze coins due to it clearing the off-hand last. (does this make sense? xD). I am trying to find a solution but I might need to make the downgrading a trigger as well :/

#

should be the last problem to fix though !

summer holly
#

An okay I see, you could use "/item replace" right?
if not then a Trigger could work as long as it doesn't downgrade all of your coins since you wouldn't be able to buy something that's like 12 silver and 5 bronze since it you tried downgrading 13 silver into 12 silver and 10 bronze but if it downgraded everything it would do 130 bronze instead.

dusk summit
#

well

#

I'm a genius 😎

#

made an item modifier to fix it

summer holly
#

:o

#

So what does the modified fix tho? xD

dusk summit
dusk summit
summer holly
#

Oh epic!

dusk summit
#

so it only converts the amount of coins you put in the offhand

summer holly
#

Nice

#

I would test it rn but as I said can't use my pc but I'll check it tomorrow

dusk summit
#

Once you have the time check it out and let me know if you like anything changed or added, (mention me tho since I won't actively check this thread anymore)

#

no worries πŸ™‚

summer holly
#

Alright, tysm for this :D

dusk summit
#

with pleasure !

summer holly
#

@dusk summit, it works great! I updated the readme to have the new way of upgrading and downgrading, and I have added a /function cheats:all and changed the cheats to give 64 instead. (it seems you have also helped me figure out how to do some things with datapacks too xd) but yeah here is the updated one

dusk summit
#

Awesome! Glad you liked it and even better you learned something of it, datapacks are Hella handy and if there's any thing ever I can advice you on, is to do some research about them. The possibilites are nearly endless

dusk summit
summer holly
#

alright, tysm again :D

#

infact from what I have just learned I think I could try just make a dead simple pack that just turns the itemframe im looking at invisible (since I already know how to do commands and such :D)

dusk summit
#

Epic! Good luck with that!

summer holly
#

it was actually really easy already finished it