Jump to content

how to /giveitem a tapestry


Go to solution Solved by MKMoose,

Recommended Posts

Posted

hi all. i play on a large pop vanilla mp server. 

we had a server desync today while i was moving some complete tapestry sets. the items vanished. we can see them in the .json item logs, then they are gone.

we have very helpful admins who can help, IF i can figure out specific commands. tapestries do not appear in the creative mode item menu.

my question: how do i /giveitem a tapestry? xXx_ape_xXx has a great solution in the linked thread. but it is not working for me so far. tapestries appear to be unusual items?

i ran around in a SP game in creative mode and found some tapestries to analyze. from those, i pulled some code. here is what i am trying as an example:

/giveitem tapestry-north{"type": "tempstorm-11"} 1 p[]

but no luck- it says error in argument- no such item exists. if anyone can help, i would appreciate it.

  • Solution
Posted

This should work:

/giveblock tapestry-north 1 { type: 'name1' }

Where 'name1' should be replaced with the appropriate type, like 'tempstorm11' for your case.

You can probably find the available types in %AppData%/VintageStory/assets/survival/blocktypes/cloth/tapestry.json or something like that, or I can get them for you a bit later if need be.

Posted

yes! thank youd MKMoose! your response plus the stuff from xXx_ape_xXx form the solution!

in my case, there are 3 important details i needed to understand: 1) tapestries are not items, they are blocks! and 2) understanding attribute formatting, and 3) learning types for tapestries.

here is the solution that worked for us. i lost the full set of 3 Ambush tapestries. the code to replace it is:
/giveblock tapestry-north 1 [my_player_name] { type: 'ambush1' }

where tapestry-north is the block (it could have been east, west, or south, but north was a fine default). 1 is the quantity. i replaced [my_player_name] with my ingame name so the admin could give the item to me without spawning it in to himself then delivering it to me. and 'ambush1' is the left portion of this 1x3 tapestry set. i also did the same code for 'ambush2' and 'ambush3' to complete the set. et-voila!

quick note: the type formatting is NOT consistent! if the entire tapestry is 1xN wide or Nx1 tall, it just uses the tapestry name followed by a number. ie: rickbat1, rickbat2.
if the tapestry is NxM as in a 2x2, then you need to use a grid. but the grids appear to be alphanumerically iterative by revision, so sometimes they require something special in the numbering. this might become more of an issue in the future as the alphas of the game progress.

example: tempstorm is 2x2, so the types are
tempstorm11   tempstrorm12
tempstorm21   tempstorm22

whereas the schematic tapestry is also 2x2, but the types are
schematic-a11 schematic-a12
schematic-a21 schematic-a22

note the '-a' there at the end- i suppose this is the second version of this tapestry. if you just use the numbers without the '-a' it spawns an invalid item which can/does crash the game.

i hope that this info is helpful to players in the future! thank you MKMoose for your help!

  • 1 month later...
Posted

Well, I have the same issue and was trying to get my tapestries back... but the command does not work at all. It's so weird because I was able to spawn tapestry via commands before, but when I put in /giveblock tapestry-south 1 and say { nightfall1 } or something, it just hangs up completely on everything after the quantity. So, the only command I can issue for tapestry is /giveblock tapestry-[north,south,etc], [quantity].

If I add anything after the quantity value, it gives me "An Exception was thrown while executing Command: Unexpected character encountered while parsing value: n. Path ", line 0, position 0.. Check error log for more detail."

I can issue the command with quantity and it just gives me an untextured tapestry. I cannot get any of the attributes working and I haven't seen anyone else have syntax errors like this. There must be something I'm missing.

Posted (edited)
17 hours ago, Laholder said:

If I add anything after the quantity value, it gives me "An Exception was thrown while executing Command: Unexpected character encountered while parsing value: n. Path ", line 0, position 0.. Check error log for more detail."

I reproduced your exception. Make sure you exactly follow the syntax (though you can use double quotes instead of single quotes, and maybe there's some leeway for whitespaces):

/giveblock tapestry-north 1 { type: 'nightfall1' }

In case that doesn't work in multiplayer, you can try setting the target to self:

/giveblock tapestry-north 1 s[] { type: "nightfall1" }
Edited by MKMoose
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.