How to Use Jigsaw Blocks to Make Custom Randomly Generated Structures

preview_player
Показать описание
Roguelike dungeons, randomly generated houses, villages, jigsaw blocks are a powerful, underutilized building tool. This tutorial will teach you how to use this little-known block as well as how to generate random structures through the use of a custom template pool (kinda like a table of contents, but with randomness).

0:00 "Intro"

0:12 "Step 1: Rooms"
- /give @p structure_block

2:38 "Step 2: Connectors"
- /give @p jigsaw

7:48 "Step 3: Custom Template Pools (Table of Contents)"
- Rename NAMESPACE folder to a short name (only using lowercase and underscores)*
- Rename TEMPLATEPOOL JSON file to a short name (only using lowercase, numbers, and underscores)
- Inside the TEMPLATEPOOL file rename NAMESPACE, TEMPLATEPOOL to their respective names
- Also inside the TEMPLATEPOOL file rename STRUCTURENAME to the name you saved in the structure block

13:36 "Step 4: Jigsaw Settings"

14:52 "Step 5: Generate!"

Advanced Info!
- Sideways jigsaws only connect to other sideways jigsaws and vertical jigsaws only connect to other vertical jigsaws
- Your structure files are saved at Your_World/generated/minecraft
- You can copy these into the datapack from PlanetMinecraft inside the your-title-goes-here/data/NAMESPACE/structures/
- If you copy your structure files you must update their location inside the TEMPLATEPOOL JSON file and replace the minecraft:STRUCTURENAME with NAMESPACE:STRUCTURENAME
- You can also prefix connectors with your namespace (i.e. talon:walkside) just make sure to change it everywhere and save it in the TEMPLATEPOOL JSON file
- Jigsaws have super cool logic when using block states. If you define a directional block state such as oak_log[axis=x] the jigsaw block will apply this before rotating the structure meaning the oak log will always be facing the correct direction
- Block states are found by pressing F3 and looking on the right side of the screen
- Block names (for the Turns Into setting) can be found by pressing F3 + H and hovering over the correct block
- You can actually set one of the structures in the template pool to be empty so the structure will occasionally not generate anything
- The Billys (cats) generated with structure did generate randomly but they all kept the Silent:1b tag I gave them, so entities do keep some tags they're saved with (the normal tags affected by spawn will be randomized)
- A more complete definition of levels is that it defines the length of a path. A single path can branch off into many other paths as well as double back on itself creating far more than seven total structures. This means the more jigsaw blocks a single structure has the more branches that structure will create and the larger the final product will become.

Edit for 1.19: World and finished datapack have been updated for 1.19. Due to some changes the template pool file had to be split for more consistent generation. Basically, you need one template pool file per exclusive connector name. So in the world the green, orange, and purple room all had the walkside connector, but the cat structure did not. So I put the cat structure in its own template pool file and updated the structures saved in the world. It makes no difference how many template files you have so if you get the no starting jigsaw found error consider adding another template pool file for any exclusive connector names.

I put as much info as I could in the advanced section, but if you still have more questions ask them, and I'll do my best to answer each one.

Ending Music:
Licensed under Creative Commons: By Attribution 3.0

Not an official Minecraft product. Not approved by or associated with Mojang.

Chapters:
0:00 "Intro"
0:12 "Step 1: Rooms"
2:38 "Step 2: Connectors"
7:48 "Step 3: Custom Template Pools (Table of Contents)"
13:36 "Step 4: Jigsaw Settings"
14:52 "Step 5: Generate!"

#JigsawBlock #RandomlyGeneratedStructuresInMinecraft #Talon2863
Рекомендации по теме
Комментарии
Автор

*FAQ (Frequently Asked Questions)*

*Issues:*
*- My jigsaw won't generate. How do I fix it?*
This can be caused by the smallest mistake. You'll need to debug your target pool and structures to discover why it's not working. See the debugging section below.
*- Does this work in Bedrock? (Or console? Mobile? Windows 10 Edition?)*
Unfortunately, no. The jigsaw block exists, but there's no way to set a target pool (which is required to generate a dungeon). Even add-ons cannot fix this. Only the developers of Bedrock can change this.
*- Does this work in version 1.X?*
*- What is Selection Priority and Placement Priority?*
*- I got the error: no starting jigsaw ROOM_NAME found in start pool TARGET_POOL.*
*- I got the error: empty or non-existent pool.*
This means your syntax (the order things are in) is wrong in your target pool file. You'll need to debug it. See the debugging section below.
*- I got the error: Missing key in ResourceKey[minecraft:root / / TEMPLATE_POOL:POOL_NAME].*
You may have renamed the template_pool folder, which will cause errors. Make sure you only rename the template_pool.json file. (Credit: knighy64)
If in 1.21, you may need to rename your "structures" folder to "structure" due to folder naming conventions introduced in 1.21. (Credit: IB-jw7bk)
*- I got the error: something is wrong in line X column Y.*
This means your syntax (the order things are in) is wrong. Go to line X column Y and work your way backwards until you can figure out the mistake. If you need some ideas of what to look for, see the debugging section below.
*- I'm confused about connectors (name and target name).*
You can think of target name like a flyer for a lost dog. It's the instructions on what to look for. Name is like the actual dog, and the generation is like you taking a flyer and then looking for the dog until you find it.
*- I'm confused about the rarity of rooms.*
Think of rarity like raffle tickets instead of a percentage. The more you put in, the better chance you have of getting that result.
*- I got two folders named your-title-goes-here.*
This sometimes happens with zipped folders. Remove one of the your-title-goes-here folders so your file structure looks like
*- I got a warning about using experimental settings. Did I do something wrong?*
No, everything's fine. Just click "I know what I'm doing."
*- The datapack I downloaded didn't work.*
*- My structures folder is empty.*
See "Can this work on a server?"

*Additions:*
*- Can you make dungeons naturally generate?*
*- Can you go over the max of seven/make an infinite number of rooms?*
Yes, but it's advanced and it tends to collide with itself. You'll have to design the logic yourself using command blocks.
I would start by putting a marker armor stand in each structure and then running the /place command on any armor stand that is all alone (since jigsaw rooms that spawned next to each other would have two marker entities in close proximity)
*- Can this work on a sever?*
- Simply copy the structure files from
- Make a new folder called "structures" inside your datapack so it looks like
- Paste the structure files into the new folder
- Copy the datapack contained in the SINGLEPLAYER_WORLD/datapacks folder
- Paste it into the MULTIPLAYER_WORLD/datapacks folder
- OR upload the datapack to your respective server host (not all of them accept uploaded datapacks)
*- Can I make a dungeon without a datapack?*
Technically yes, but I don't know how. You would have to design the command block logic yourself and use the /place command to set each individual room based on that logic.
*- Can you activate jigsaws automatically?/Generate a specific structure?*
Yes, very easily. Just use /place template minecraft:ROOM_NAME ~ ~ ~. You can also do the whole dungeon with /place jigsaw NAMESPACE:TARGET_POOL CONNECTOR_NAME 7 ~ ~ ~.
*- Can you guarantee one room spawning at the end of the dungeon?*
Yes, using fallback pools. If you specify a template pool for the fallback key in the TARGET_POOL file, then when the dungeon finishes generating but still has open connectors, the fallback pool will be used to close those connectors. (Credit: griglog1309)
*- Can you make rooms not collide?*
Technically yes, but I don't know how. My guess is that this is super advanced because you would have to design your own command block logic to do a ton of checks before placing a single room.
*- Can you have multiple pools in one namespace?*

*Debugging Steps To Try:*
- Double check if your structures work by themselves. You should be able to summon each room individually using /place template minecraft:ROOM_NAME ~ ~ ~
- For each room you'll want to double check each jigsaw block has the correct "Name" and "Connector Name"
- In target pool file double check that all "{" have an opposite pair (this has caused me problems many times)
- Make sure all commas are in the right place (such as after each room)
- Make sure there are no unnecessary commas (there should not be one after the last room in the list)
- Make sure all the names and file locations are correct

*If you have additional questions, comment below.*

Talon
Автор

Your dungeon is like a McDonald’s play space.

curseofcrits
Автор

this is the only good jigsaw tutorial in existence, I greatly appreciate it

ordanarymods
Автор

OK i admit it was a *BIT* clunky to follow at first BUT I got the hang of it pretty quickly and this is LEGIT the best jigsaw tutorial in existence that I've seen thus far. I'd love to see a smoother updated version, but for now this STILL works, good work

admiral_m_k
Автор

up until now, I could only find videos telling me a very vague description of the jigsaw block or straight up saying they have no clue how it works. When I find your video, I was super happy to find someone who actually knows how to use it and how to teach others in a in depth tutorial, so thank you!

xreverse_fash
Автор

Hey guys!
It notices you can make your own structures using Villages, Pillager Outpost and Bastions as base.
Some days ago, I saw a comment saying you can't generate custom structures without overwriting vanilla ones.
I decided to check if it was true and a I noticed NO.
You can make new structures!
If you want to make them spawn in some Biomes, you have to add the start pool of the structure in the Biome JSON.

I hope this helps ;)

rubenciogd
Автор

The video came out 3 years ago and the creator is still replying to comments for help, massive respect

Cat_Username
Автор

this tutorial is amazing! You explained things very well, the colored rooms were very easy and good examples, and your voice is pretty calming~
I remember spending SO much time creating a custom floating island dungeon. I wish I knew about this beforehand!
Now I will be able to attempt and put all this knowledge to use and.... recreate the whole thing... and hopefully make it even better~ 😅

Great tutorial! Tank you so much for making this! 🥰💖

Leanda
Автор

It's amazing that the sculpture blocks made available as data packs.

StructureGoin
Автор

Thank you so much for this. Doing json custom biomes etc and this is a really good starting point for me in custom structures. Still not sure how to implement them in the biomes but that’s the next step

samuelvink
Автор

You are a *brilliant* teacher. Thank you so much for this! The datapack part was so well explained.

brannanvitek
Автор

thank you! i was making a custom medival structure and almost every time the roads wouldnt generate. very helpful and probably the best tutorial someone could find :)

hmsko
Автор

This tutorial was very cool man. I really wanted to duplicate the backrooms and make different levels. This is very helpful and useful. You deserve more subs

CrezzyCreeper
Автор

Most youtubers would explain what a jigsaw block is, and how it works, but not how to use it. Nah, this video is the best one.
If only people knew how they work on bedrock too.

MKGInfinity
Автор

Great. Now we need a tutorial on processor lists.

erie
Автор

Absolutely legendary tutorial, you've def earned a new sub! Thanks so much :)

luckylucas
Автор

"Even the cats are randomly generated its PURR-fect"
Good pun right there

Quidney
Автор

this would be awesome to make a map where a maze is randomly generated.

rycer
Автор

Best jigsaw tutorial the only useful one on youtube and i needed only 3 rewatches to understand it :D

yupeca
Автор

ive been doing work on mc for as long as its been around, & jigsaw blocks were always a huge pain in the ass to try to understand, so thank you, this really clarified a Lot & is a great jumping off point to learning some of the More complex parts of it.

AthesielIcosiel