Nickitkat Posted July 29 Report Posted July 29 (edited) Hi, I'm starting to regret my material choices for my base in survival. I wish to swap them but the thought of replacing everything block by block is really discouraging. I can't phantom how long it would take to change them all and I don't even know if the new material palette would look good until I test them out somehow. I've tried world edit. Creating a bounding box selection, using rep mat only works for full 'blocks' and support beams so far. Slabs, chiseled blocks and fence doesn't seem to work. Right clicking them with the new block I wish to replace also doesn't work. I've downloaded QP's chisel mod, but I don't know how to make the block swapper tool work on an entire selection. Not to mention, it doesn't work on chiseled blocks. Basically I'm just trying to swap all pine related blocks or texture to walnut. Please help me ! Thanks! P.S - English isn't my first language, I apologize if my sentences cause confusion or if they could be worded better. Sorry! Edited July 29 by Nickitkat 1
Professor Dragon Posted July 30 Report Posted July 30 (edited) Hello @Nickitkat, Welcome to the forum. I've tried on v1.22.5 (Stable) with World Edit, Paintbrush tool and can replace fences and slabs one by one with a right click. The method has two parts: 1) Bound your Selection to be ONLY the parts you wish to replace with the select block. Taking an example from your windmill, this might be every fence in the front fence selection only. Use "/we constrain selection" 2) Change the Paint Brush tool to Mode "Replace Selected Block", put the block that you wish to replace into your Hot Bar slot and then you can <right mouse> drag and only items within the bounded selection (1) will be replaced. CAUTION: This does NOT check for original block type - it just overwrites whatever block is there. I found this method from Tyron, the lead developer in another thread: "1.19 allows you to constrain all tool brush operations to your selection via "/we constrain selection". That plus a large enough paint brush with place mode "Replace selected" should about do the same thing." There is also "Chisel brush Tool" which I THINK does something similar for chiselled blocks, but have not tested. I'm pretty sure that the QP chisel mod can help to some extent, but you'd need to go watch a video for that to confirm. The downside is that you will need to do that selection for every part of your build. It is not a "search and replace all" ability. This makes it good for things like a large section - such as a big, uniform wall. But poor for a complex build with lots of little parts. Honestly, moving over to Creative and replacing it block by block might be easier. Hello @Tyron, Is it possible to do a "Search and Replace" on a bounded section in a build? For example, to bound a whole build and replace pine fences with birch fences? Or is this a case for an Export, text file search and replace, and Import? Thanks, Professor Dragon. EDIT Hello @Nickitkat - I experimented some more, and I think that doing an Export and then manipulating the text file is the way to go for you. 1. Select and bound your build. 2. Export the build eg "/we export D:\MyVSExport.json" This will generate a file with contents similar to the following: {"GameVersion":"1.22.5","SizeX":4,"SizeY":1,"SizeZ":3,"BlockCodes":{"11667":"game:woodenfence-purpleheart-empty-free","7575":"game:cobblestoneslab-sandstone-down-free","11704":"game:woodenfence-baldcypress-s-free","11732":"game:woodenfence-baldcypress-ne-free"},"ItemCodes":{},"Indices":[1024,2048,1,1025,2049,2,1026,2050,1027,2051],"BlockIds":[11667,7575,7575,7575,7575,7575,7575,7575,11704,11732],"DecorIndices":[],"DecorIds":[],"BlockEntities":{},"Entities":[],"ReplaceMode":2,"EntranceRotation":-1,"OriginalPos":{"X":511964,"Z":511890,"InternalY":114}} 3. Manipulate the text file with a Search and Replace (I find Notepad++ useful, but even basic Notepad will work). TIP: Make up a simple build with the block types in your original build, and the block types in your replacement parts - this will give you a list of both names. 4. Import the file with World Edit. Professor Dragon. Edited July 30 by Professor Dragon
Nickitkat Posted July 31 Author Report Posted July 31 (edited) UPDATE: I figured out how to make it work. So, I am leaving this here in hopes that it will help you instead. There are 2 methods I have discovered. But you must first: Enable creative mode Give yourself a Magic Wand Press "~" Select 'Select Tool' on the left toolbar While using magic wand. Left click to set first selection point, right click to set final selection point. The end result is a highlighted area showing your selection 'zone'. This zone should encompass all the blocks/structure/buildings that you wish to swap blocks. (Note that when having the ~ menu open you can't look around, so make your first selection then close the menu, fly to your second point and open the menu and make your second selection) Use the U+ U- D+ D- buttons to set your selection's Z axis. Also, you can adjust your selection zone size using the N E S W +- buttons. These buttons are located at the top of your screen Change the 'Constrain' drop down menu to 'On' - Important! Done. Now moving on to the 2 methods. Method 1: Swapping Blocks using '/we repmat' Command With your selection zone set, make sure: Hotbar 0 is the block you want to be swapped. The block that you want it to swap to can be at any hotbar but you must be selecting it. Type /we repmat All the blocks in hotbar 0 in your zone will swap to the block in your active selection hotbar. For example if you wish to swap granite cobblestone to andesite cobblestone. Granite cobblestone should be in hotbar 0, andesite cobblestone can be in any hotbar as long as it is selected. Type the command and it should swap. This will swap chiseled blocks as well. If you have a chiseled pine block with some granite voxels on it, the granite will change to andesite when you run this command. If this method doesn't work for some reason, move to Method 2. Method 2: Swapping Blocks using Paintbrush in WorldEdit (Pressing '~') If Method 1 doesn't work, then press '~' and select 'Paintbrush' button on the left Set your desired paintbrush size by adjusting the values of the SizeX,Y,Z Now, with the block you wish to swap to in your active hotbar, right click on the block you wish to swap This will place the block, but it will immediately disappear and the block you wish to swap will all swap to what you want, but only the same block type within the paintbrush's selection area will be affected. If it doesn't work, it is most likely because something is preventing the block from being placed down. It has to be able to be placed down adjacent to the targeted block first before being able to affect all other blocks. Note So far, both method doesn't work for doors, trapdoors, fences, slabs and maybe other blocks which I haven't tested. These will have to be manually replaced. Sometimes, chiseled blocks doesn't swap. In this case, you might have to download QP's chisel mod to ease the process of transferring chisel patterns to a different block assuming your chisel work doesn't involve other block types and is purely just form. P.S - Thank you @Professor Dragon for replying to my query. You have been very helpful . I hope this helps you fellow Vintarian. Edited July 31 by Nickitkat 1
Professor Dragon Posted July 31 Report Posted July 31 Thank you so much for the detailed reply! I didn't know about the use of the "/we repmat" command, and that is a powerful ability. Nice write up. Glad to help. Professor Dragon.
Recommended Posts