When you start a path with a forward slash, it means the path is starting from your system root. Instead try "~/.minecraft/saves/World3", which starts from your home folder. You could also use "./.minecraft/saves/World3", which starts from your current directory, since your current directory is your home folder in this case.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
[ERROR] FATAL UNHANDLED EXCEPTION: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
Argh. The problems never end. That happened if I tried with the tilde symbol, and the period in front of the world path gave this output:
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
[ERROR] FATAL UNHANDLED EXCEPTION: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
I'm sorry I keep screwing this up, but maybe something good will come out of it.
Rollback Post to RevisionRollBack
Life is like a clogged toilet: It's full of crap until you do something worth remembering in it.
Only you can determine what the correct path is, so the first thing you need to do is confirm what the actual path is.
Try navigating to your save folder, so if you think the correct path is ~/.minecraft/saves/World3, then try the following:
user@host ~]$ cd .minecraft
user@host .minecraft]$ cd saves
user@host saves]$ cd World3
user@host World3]$ ls
data level.dat ...
A helpful command is "ls -alh", which will show all files and directories in your current directory, including hidden ones. The .minecraft directory is hidden.
Only you can determine what the correct path is, so the first thing you need to do is confirm what the actual path is.
Try navigating to your save folder, so if you think the correct path is ~/.minecraft/saves/World3, then try the following:
user@host ~]$ cd .minecraft
user@host .minecraft]$ cd saves
user@host saves]$ cd World3
user@host World3]$ ls
data level.dat ...
A helpful command is "ls -alh", which will show all files and directories in your current directory, including hidden ones. The .minecraft directory is hidden.
Save path is correct. ~/.minecraft/saves/World3
Do I need to select some part of my save, like level.dat?
It wasn't difficult to add though, so I've uploaded a new version of the tool with --di, --dx, --dir, and --der flags for also filtering on data.
I'm also curious, did you actually try specifying block IDs > 255? NBToolkit took all IDs mod 256 so that should not have been possible. I've removed those constraints as well in the latest upload.
@Shoop_Do_Whoop: I have added some extra error reporting in the latest version. It will either tell you that the location was not found, or that opening the world failed.
If the later occurs, then there might be something strange about your world that is preventing Substrate from recognizing it as valid. Try giving the path to your level.dat, and if that fails, send me a copy of your world. If it's large, you can remove most of the region files from the copy you send.
@Shoop_Do_Whoop: I have added some extra error reporting in the latest version. It will either tell you that the location was not found, or that opening the world failed.
If the later occurs, then there might be something strange about your world that is preventing Substrate from recognizing it as valid. Try giving the path to your level.dat, and if that fails, send me a copy of your world. If it's large, you can remove most of the region files from the copy you send.
That would be the best. I think that email would work for me in this case. Sorry for the problems. The fact that you have been willing to work with me so much makes this one of the most helpful threads I have ever found. Send me contact info in a PM if you are willing to do this job for me.
Rollback Post to RevisionRollBack
Life is like a clogged toilet: It's full of crap until you do something worth remembering in it.
The problem turned out to be the third party package I use to parse command-line arguments. It was converting everything to lowercase, which is fine for Windows but not fine for Linux.
I've uploaded a new version with this fixed. With the fix, your world updated in a few minutes on Fedora 17 and the oak trees were as vanilla as ever.
No, Emerald is not generated with the normal ore algorithms like the others. A few individual blocks are peppered into the lower 32 blocks individually. You could approximate this with block replace instead, using a very low probability modifier (-p 0.001), and limiting the Y range to be between 0 and 32.
Actually, you *could* use oregen to generate chunks of emerald just like gold or diamond if you want, but you need to explicitly specify the parameters for rounds, size, min (Y), max (Y), etc. You can do this for any block. NBToolkit just happens to provide default values for the traditional ore blocks as defined by Minecraft.
nbtoolkit.exe replace -w "path/to/world" --bi=1 --byr=1:31 --bp=0.001 -a 129
This should approximate Minecraft's emerald generation. The probability .001 over the lower 32 layers of a chunk gives on average 8 blocks per chunk randomly dispersed. Specifying only smooth stone is replaced will further lower the probability as there are fewer "chances" of generating the ore. Minecraft is similarly pessimistic about all ore generation. If it just happened to pick a spot that wasn't smooth stone, no ore for you.
That should generate emerald like diamond: One small deposit per chunk if it found smooth stone to replace. You can up the -r (rounds) or -s (size) parameters to generate more ore. For comparison, the table of default ore parameters can be found near the top of: https://github.com/jaquadro/NBToolkit/blob/master/NBToolkit/Source/Oregen.cs
Is running multiple instances of nbtoolkit.exe at the same time (multiple command propmt) to modify the same world possible? Or does it cause problems?
1. They are for "verbose" and "very verbose" printed output. Specifying -v would print out a line for each chunk processed, whereas --vv might print out a line for every block that gets replaced, or every ore vein that gets generated.
2. It uses the same ore generation algorithm, although it does not use your world seed, so placement won't necessarily be exact. There is actually a minor difference from the current algorithm: generated ore in recent Minecraft is "biased" 2 blocks downwards, whereas oregen (and older Minecraft) biased 2 blocks upwards. I've maintained the old rule, since it's more in the player's favor with default settings.
1. They are for "verbose" and "very verbose" printed output. Specifying -v would print out a line for each chunk processed, whereas --vv might print out a line for every block that gets replaced, or every ore vein that gets generated.
2. It uses the same ore generation algorithm, although it does not use your world seed, so placement won't necessarily be exact. There is actually a minor difference from the current algorithm: generated ore in recent Minecraft is "biased" 2 blocks downwards, whereas oregen (and older Minecraft) biased 2 blocks upwards. I've maintained the old rule, since it's more in the player's favor with default settings.
Thanks once again for the answers.
One last question: is there a flag like --nbya or --nbyb, but to check the blocks at the sides? I want to keep my ores away from Stationary Lava, cave walls and mineshaft walls. That way they will always be in light level 0 and can easily be Orebfuscated in a efficient way. Yet I can't seem to find a flag for that. Anything you can think about?
I've updated the download to add a few new block filtering flags that should help you.
--nbs Will let you specify blocks that should appear on the side of the block (any side, one or more).
But what I think you actually want is exclusion flags, so I've added --nbyax, --nbybx, and --nbsx, which will cause a block to be skipped if it has one of those specified neighbors. You could specify air and lava in those flags to prevent deposits from touching lava or appearing on the surface of walls.
There's also --nb and --nbx flags, which match against any neighbor, or exclude against any neighbor (basically the same as specifying top, bottom, and side as the same thing).
The side-checking options will slow down processing a bit, since they cause chunk boundaries to be crossed. That's the main reason I haven't supported them yet -- it's a more complicated check.
For some reason I get this error quite often. It says the file is beeing used by another process. Tried running it on safe mode to check if it was another program, but the problem still happens.
The funny thing is: sometimes it happens, sometimes it doesn't. And when it does, all I gotta do is run the command again till it works.
The process cannot access the file 'C:\Documents and Settings\Marcelo\My Documen
ts\Ethereal\Ethereal\region\r.0.5.mca' because it is being used by another proce
ss.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, I
nt32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions o
ptions, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolea
n useLongPath)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access,
FileShare share)
at Substrate.Core.RegionFile.ReadFile()
Unhandled Exception: System.NullReferenceException: Object reference not set to
an instance of an object.
at Substrate.Core.RegionFile.Write(Int32 x, Int32 z, Byte[] data, Int32 lengt
h, Int32 timestamp)
at Substrate.Core.RegionFile.ChunkBuffer.Close()
at Ionic.Zlib.ZlibBaseStream.Close()
at Ionic.Zlib.ZlibStream.Dispose(Boolean disposing)
at System.IO.Stream.Close()
at Substrate.AnvilChunk.Save(Stream outStream)
at Substrate.ChunkRef.Save(Stream outStream)
at Substrate.RegionChunkManager.Save()
at NBToolkit.Oregen.Run()
at NBToolkit.Program.Main(String[] args)
Is Oregen usable to generate blocks in the Nether or End?
Rollback Post to RevisionRollBack
If you have ask "Is using X cheating?", the answer is most likely yes. Being a sandbox game doesn't change the fact you are cheating in it, regardless of what people say. However, the question you should be asking is "Does it matter?" The answer to that question is no.
There's a nether switch, but I'm not sure it's valid anymore. You could temporarily copy your level.dat into your DIM1 or DIM-1 folders, and then point to that as your world folder. None of the tools should care.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
[ERROR] FATAL UNHANDLED EXCEPTION: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
[ERROR] FATAL UNHANDLED EXCEPTION: System.NullReferenceException: Object reference not set to an instance of an object
at NBToolkit.Replace.Run () [0x00000] in <filename unknown>:0
at NBToolkit.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
Try navigating to your save folder, so if you think the correct path is ~/.minecraft/saves/World3, then try the following:
user@host ~]$ cd .minecraft
user@host .minecraft]$ cd saves
user@host saves]$ cd World3
user@host World3]$ ls
data level.dat ...
A helpful command is "ls -alh", which will show all files and directories in your current directory, including hidden ones. The .minecraft directory is hidden.
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
Save path is correct. ~/.minecraft/saves/World3
Do I need to select some part of my save, like level.dat?
It wasn't difficult to add though, so I've uploaded a new version of the tool with --di, --dx, --dir, and --der flags for also filtering on data.
I'm also curious, did you actually try specifying block IDs > 255? NBToolkit took all IDs mod 256 so that should not have been possible. I've removed those constraints as well in the latest upload.
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
If the later occurs, then there might be something strange about your world that is preventing Substrate from recognizing it as valid. Try giving the path to your level.dat, and if that fails, send me a copy of your world. If it's large, you can remove most of the region files from the copy you send.
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
That would be the best. I think that email would work for me in this case. Sorry for the problems. The fact that you have been willing to work with me so much makes this one of the most helpful threads I have ever found. Send me contact info in a PM if you are willing to do this job for me.
The problem turned out to be the third party package I use to parse command-line arguments. It was converting everything to lowercase, which is fine for Windows but not fine for Linux.
I've uploaded a new version with this fixed. With the fix, your world updated in a few minutes on Fedora 17 and the oak trees were as vanilla as ever.
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
I am trying to, but does not work with.
Actually, you *could* use oregen to generate chunks of emerald just like gold or diamond if you want, but you need to explicitly specify the parameters for rounds, size, min (Y), max (Y), etc. You can do this for any block. NBToolkit just happens to provide default values for the traditional ore blocks as defined by Minecraft.
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
Thanks.
Can you suggest some parameter for emerald generation for old 1.3.5 map?
I will very appreciate.
nbtoolkit.exe replace -w "path/to/world" --bi=1 --byr=1:31 --bp=0.001 -a 129
This should approximate Minecraft's emerald generation. The probability .001 over the lower 32 layers of a chunk gives on average 8 blocks per chunk randomly dispersed. Specifying only smooth stone is replaced will further lower the probability as there are fewer "chances" of generating the ore. Minecraft is similarly pessimistic about all ore generation. If it just happened to pick a spot that wasn't smooth stone, no ore for you.
You can also try...
nbtoolkit.exe oregen -w "path/to/world" -b 129 -r 1 -s 7 --min=0 --max=15
That should generate emerald like diamond: One small deposit per chunk if it found smooth stone to replace. You can up the -r (rounds) or -s (size) parameters to generate more ore. For comparison, the table of default ore parameters can be found near the top of: https://github.com/jaquadro/NBToolkit/blob/master/NBToolkit/Source/Oregen.cs
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
Alright, thanks for the fast reply. I've got a few more questions, if you could please help me.
1. What does -v and --vv do?
2. Does the oregen always follow the original Minecraft map generator to generate the ores, no matter the options?
2. It uses the same ore generation algorithm, although it does not use your world seed, so placement won't necessarily be exact. There is actually a minor difference from the current algorithm: generated ore in recent Minecraft is "biased" 2 blocks downwards, whereas oregen (and older Minecraft) biased 2 blocks upwards. I've maintained the old rule, since it's more in the player's favor with default settings.
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
Thanks once again for the answers.
One last question: is there a flag like --nbya or --nbyb, but to check the blocks at the sides? I want to keep my ores away from Stationary Lava, cave walls and mineshaft walls. That way they will always be in light level 0 and can easily be Orebfuscated in a efficient way. Yet I can't seem to find a flag for that. Anything you can think about?
--nbs Will let you specify blocks that should appear on the side of the block (any side, one or more).
But what I think you actually want is exclusion flags, so I've added --nbyax, --nbybx, and --nbsx, which will cause a block to be skipped if it has one of those specified neighbors. You could specify air and lava in those flags to prevent deposits from touching lava or appearing on the surface of walls.
There's also --nb and --nbx flags, which match against any neighbor, or exclude against any neighbor (basically the same as specifying top, bottom, and side as the same thing).
The side-checking options will slow down processing a bit, since they cause chunk boundaries to be crossed. That's the main reason I haven't supported them yet -- it's a more complicated check.
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate
The funny thing is: sometimes it happens, sometimes it doesn't. And when it does, all I gotta do is run the command again till it works.
Speaking of which, the command I'm using is:
ts\Ethereal\Ethereal\region\r.0.5.mca' because it is being used by another proce
ss.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, I
nt32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions o
ptions, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolea
n useLongPath)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access,
FileShare share)
at Substrate.Core.RegionFile.ReadFile()
Unhandled Exception: System.NullReferenceException: Object reference not set to
an instance of an object.
at Substrate.Core.RegionFile.Write(Int32 x, Int32 z, Byte[] data, Int32 lengt
h, Int32 timestamp)
at Substrate.Core.RegionFile.ChunkBuffer.Close()
at Ionic.Zlib.ZlibBaseStream.Close()
at Ionic.Zlib.ZlibStream.Dispose(Boolean disposing)
at System.IO.Stream.Close()
at Substrate.AnvilChunk.Save(Stream outStream)
at Substrate.ChunkRef.Save(Stream outStream)
at Substrate.RegionChunkManager.Save()
at NBToolkit.Oregen.Run()
at NBToolkit.Program.Main(String[] args)
Mods I Develop: Garden Stuff -- Storage Drawers -- Hunger Strike
Tools I Develop: NBTExplorer -- Substrate