Hey. First of all, thanks for the great tool. MC Edit is helping me quite a lot in making my adventure map (with the new adventure mode).
I could use your help in creating a filter.
Here is the problem. I made a huge structure out of stone bricks and now I want a filter that will randomly pick stone bricks and replace them with cracked and mossy stone bricks. I've made the filter.
The user picks block A (in my case stone bricks) and block B (in my case cracked or mossy stone bricks).
He also inputs the chance of replacing the blocks (default 15%).
And everything works fine if I want to change blocks with different ID's. But when I want to change blocks with same ID's but different .blockData, it doesn't work. It just replaces them with the first, default block ID (instead of placing cracked stone bricks, it will just place stone bricks).
Here is my filter code:
import random
inputs = (
("Pick block A:", "blocktype"), #Block that will be replaced
("Pick block B:", "blocktype"), #Block that will replace it
("Chance", (15, 1, 100)),
)
def perform(level, box, options):
chance = options["Chance"]
blockTypeA = options["Pick block A:"].ID
blockTypeB = options["Pick block B:"].ID
changeChance = float(chance) / 100.0
for x in xrange(box.minx, box.maxx): #nasty loop to go trough every block in the selection box
for z in xrange(box.minz, box.maxz): #not sure if I could use the other 2 methods since
for y in xrange(box.miny, box.maxy): #I don't see them checking every block separately.
if level.blockAt (x, y, z) == blockTypeA:
if random.random() < changeChance:
level.setBlockAt(x, y, z, blockTypeB)
level.markDirtyBox(box)
I know I should use .blockData and manipulate it, but I really don't know how. TBH, I'm happy that I managed to make this filter work as it is considering that I don't know Python. Only Java, C++ and C#.
I wouldn't be asking if I didn't need your help. But I asked around, people I know made some filter (but they completely ignored the message), posted a thread on Mod Discussion which was also ignored...
I hope you can help me.
But thanks anyways.
EDIT:
I made it work somehow. I looked at the level.py library and fount the setBlockDataAt command. I had some problems making it work, but it ended up working well. But get the feeling that something is off with my code.
import random
inputs = (
("Pick block A:", "blocktype"), #Picks the blocks that will be changed
("Pick block B:", "blocktype"), #picks the block to which it will change
("Chance", (15, 1, 100)),
)
def perform(level, box, options):
chance = options["Chance"]
blockTypeA = options["Pick block A:"].ID
blockDataA = options["Pick block A:"].blockData
blockTypeB = options["Pick block B:"].ID
blockDataB = options["Pick block B:"].blockData
changeChance = float(chance) / 100.0
for x in xrange(box.minx, box.maxx):
for z in xrange(box.minz, box.maxz):
for y in xrange(box.miny, box.maxy):
if level.blockAt(x, y, z) == blockTypeA:
if level.blockDataAt (x, y, z) == blockDataA:
if random.random () < changeChance:
level.setBlockAt(x, y, z, blockTypeB)
level.setBlockDataAt(x, y, z, blockDataB)
level.markDirtyBox(box)
I'm not sure if the "level.setBlockDataAt(x, y, z, blockDataB)" is included in the whole loop. I tested it and it all works well, but I'm used to have to use { and } in C++ when I want more than one command line to be included in a loop. But when I use t( and ) inn the code I always get a syntax error on the "level.setBlockDataAt(x, y, z, blockDataB)" line.
I mean, it works fine in my tests, but I still feel like it's not the correct way to do. How does the program know what to include in the loop and what not. Is the "level.markDirtyBox(box)" also included in the loop because there is no way of telling what commands are and what aren't in it. If it is, it's just taking away resources for no reason because it's needed only once at the end of the filter to say that the selection needs to run a lightning check or whatever.
When i got that intel version same thing popped up imidiately when i clicked to load a map. Yes it crashes on loading a map.
How could i know that my world is big?
Not long ago minecraft started eating memory like crazy. After playing 5-10 minutes on surface it uses more than a gigabyte of listfile and 700mb of ram and it lags a lot. when i'm minig it is not so bad but still laggy.
That thing started when i got xray mod. reinstalling didn't help it lags all worlds now even new ones.
May be it's because i use x ray. it reloads chunks.
Is there any chance of a future intel card fix? I have seen many videos about this program and I would love to be able to use this. I'm sorry if this is a stupid question or has been answered before. In case you may know what part is causing the error I may be able to go in myself and try to make my own fix so if you do, please, do share.
Today I tried to run minecraft on other pc, a better one.
I realized that my maps was broken. I tried 12w26a and converted my worlds into that format. But then i refused to play on that version because that was laggy. and turned back to old format. That was a problem.
Since that time it started glitching. Xray was installed accidentally on the same week. So i didn't mention that. Today i tried to create new world and it worked fine. But my old ones runs out of memory when you will try to travel more than 4 chunks,
I've tried to create a new world. collected some resources, saved. MCEdit still crashes the same way. About Xray, it affects only rendering allowing to render only special resouce types like ores and everithing handy.
Is there any chance of a future intel card fix? I have seen many videos about this program and I would love to be able to use this. I'm sorry if this is a stupid question or has been answered before. In case you may know what part is causing the error I may be able to go in myself and try to make my own fix so if you do, please, do share.
The program is open-source, so you could try making a fix if you tracked down the problem, and I'm sure many people here would appreciate it. The cause of the error isn't exactly known; a handful of people have tried tracking it down and fixing it, but to no avail. TkTech, the primary maintainer, has stated he can't solve the problem because he has no machines which have the problem, and is therefore unable to track down the source of the issue (error reports aren't enough; he'd actually need a machine with the issue to be able to work it out).
If you have knowledge of Python and actually manage to make a fix, you'd probably halve the number of incoming posts for this thread
(considering how many have complained of this error)
Hi,
I'm working on a CTM map, and Importing some dungeons I designed earlier. I'm exporting from one map into another.
Four of my five dungeons I've completed import fine, but the fifth gives the following error:
I don't know how to import this file: Dungeon III - Blackspine Caverns.schematic
Error: LoadingError(('Multiple errors encountered',
NBTFormatError('Not an NBT file with a root TAG_Compound
(Found 31)',), IOError()'MCJavaLevel attempted for smaller
than 64 blocks cubed',)), <traveback object at 0x32CD0C38>
I'm not sure about that "Smaller than 64 blocks cubed" is about, the cave is massive.
It'd be much appreciated if anyone could explain this to me, even more so if someone has a solution.
(I ran a search of this topic, but didn't' find anything.)
Rollback Post to RevisionRollBack
Sigma_Phi - home of the long-winded answers to questions nobody asked.
Whoever created this program needs to get a brain this is the crappiest program i ever used!!!!!
END OF SUBJECT.
And I am sure that the world editor that YOU made is soooo much better.
Please provide a link, and evidence of the joy it has brought to the Minecraft community.
Hi,
I'm working on a CTM map, and Importing some dungeons I designed earlier. I'm exporting from one map into another.
Four of my five dungeons I've completed import fine, but the fifth gives the following error:
I don't know how to import this file: Dungeon III - Blackspine Caverns.schematic
Error: LoadingError(('Multiple errors encountered',
NBTFormatError('Not an NBT file with a root TAG_Compound
(Found 31)',), IOError()'MCJavaLevel attempted for smaller
than 64 blocks cubed',)), <traveback object at 0x32CD0C38>
I'm not sure about that "Smaller than 64 blocks cubed" is about, the cave is massive.
It'd be much appreciated if anyone could explain this to me, even more so if someone has a solution.
(I ran a search of this topic, but didn't' find anything.)
How was that schematic file created? MCEdit is pretty picky about its schematics.
(Also, you didn't actually link the schematic. Just giving the name is kinda useless.)
How was that schematic file created? MCEdit is pretty picky about its schematics.
(Also, you didn't actually link the schematic. Just giving the name is kinda useless.)
The schematic file was created IN MCEdit. I'm using MCEdit to pull a dungeon from one map and drop it another.
And, excuse my stupid, but how would I like the schematic here?
Rollback Post to RevisionRollBack
Sigma_Phi - home of the long-winded answers to questions nobody asked.
i have a couple things that im having happen in my version (0.1.1-1-g41ea the 64 bit one). When i select an area and use the green nudge button to move it around when the field passes through anything else it deletes it (if this has been mentioned before sorry).
id also be wiling to help with the whole intel problem, though if need someone to guide me through it, as i have no idea how to code or anything (like if someone without intel knows how to ect...)
Hey, thanks for the response, but I figured it out. Sort of.
I split the dungeon in half and imported the halves, and it worked. Go figure.
Well, thank you!
Rollback Post to RevisionRollBack
Sigma_Phi - home of the long-winded answers to questions nobody asked.
You don't "allocate" RAM like you would with Minecraft, MCEdit manages its memory usage automatically. If you still run out of memory you're simply doing more than the program can handle.
i have a couple things that im having happen in my version (0.1.1-1-g41ea the 64 bit one). When i select an area and use the green nudge button to move it around when the field passes through anything else it deletes it (if this has been mentioned before sorry).
id also be wiling to help with the whole intel problem, though if need someone to guide me through it, as i have no idea how to code or anything (like if someone without intel knows how to ect...)
That thing with the Nudge feature is intentional and it's been coded in as long as I can remember.
You'll have to learn to code, no other programmer will baby you. Thankfully if you've got the right mindset it's not too hard.
Start by downloading Python and playing around in the interpreter. Follow an online tutorial to make basic programs. I'm not going to link you to any of this - if you can't use Google to find things out for yourself programming won't be your forte.
lol I can't even use it. It crashes on loading always.
btw is it OK that minecraft also crashes if i travel some chunks one way, because when i started playing it. everithing was fine. mc was littlebit laggy on my old mashine but still playable. but now it eats up all memory on my PC. On different PC's it just runs out of memory and ask to close it. It is not playable anymore.
I'm frustrated. Is it worth to try it make playable or it's just a waste of time?
You'll have to learn to code, no other programmer will baby you. Thankfully if you've got the right mindset it's not too hard.
Start by downloading Python and playing around in the interpreter. Follow an online tutorial to make basic programs. I'm not going to link you to any of this - if you can't use Google to find things out for yourself programming won't be your forte.
ok i shall try, thanks for the nudge in the right direction
I could use your help in creating a filter.
Here is the problem. I made a huge structure out of stone bricks and now I want a filter that will randomly pick stone bricks and replace them with cracked and mossy stone bricks. I've made the filter.
The user picks block A (in my case stone bricks) and block B (in my case cracked or mossy stone bricks).
He also inputs the chance of replacing the blocks (default 15%).
And everything works fine if I want to change blocks with different ID's. But when I want to change blocks with same ID's but different .blockData, it doesn't work. It just replaces them with the first, default block ID (instead of placing cracked stone bricks, it will just place stone bricks).
Here is my filter code:
I know I should use .blockData and manipulate it, but I really don't know how. TBH, I'm happy that I managed to make this filter work as it is considering that I don't know Python. Only Java, C++ and C#.
I wouldn't be asking if I didn't need your help. But I asked around, people I know made some filter (but they completely ignored the message), posted a thread on Mod Discussion which was also ignored...
I hope you can help me.
But thanks anyways.
EDIT:
I made it work somehow. I looked at the level.py library and fount the setBlockDataAt command. I had some problems making it work, but it ended up working well. But get the feeling that something is off with my code.
I'm not sure if the "level.setBlockDataAt(x, y, z, blockDataB)" is included in the whole loop. I tested it and it all works well, but I'm used to have to use { and } in C++ when I want more than one command line to be included in a loop. But when I use t( and ) inn the code I always get a syntax error on the "level.setBlockDataAt(x, y, z, blockDataB)" line.
I mean, it works fine in my tests, but I still feel like it's not the correct way to do. How does the program know what to include in the loop and what not. Is the "level.markDirtyBox(box)" also included in the loop because there is no way of telling what commands are and what aren't in it. If it is, it's just taking away resources for no reason because it's needed only once at the end of the filter to say that the selection needs to run a lightning check or whatever.
Sorry for bad English
How does the program display the world? Is it a direct interface with OpenGL or something else? What part of the source code handles that?
How could i know that my world is big?
Not long ago minecraft started eating memory like crazy. After playing 5-10 minutes on surface it uses more than a gigabyte of listfile and 700mb of ram and it lags a lot. when i'm minig it is not so bad but still laggy.
That thing started when i got xray mod. reinstalling didn't help it lags all worlds now even new ones.
May be it's because i use x ray. it reloads chunks.
So how do i know that the world is big?
Both of you, just download the newest version, on the front page.
I realized that my maps was broken. I tried 12w26a and converted my worlds into that format. But then i refused to play on that version because that was laggy. and turned back to old format. That was a problem.
Since that time it started glitching. Xray was installed accidentally on the same week. So i didn't mention that. Today i tried to create new world and it worked fine. But my old ones runs out of memory when you will try to travel more than 4 chunks,
I've tried to create a new world. collected some resources, saved. MCEdit still crashes the same way. About Xray, it affects only rendering allowing to render only special resouce types like ores and everithing handy.
The program is open-source, so you could try making a fix if you tracked down the problem, and I'm sure many people here would appreciate it. The cause of the error isn't exactly known; a handful of people have tried tracking it down and fixing it, but to no avail. TkTech, the primary maintainer, has stated he can't solve the problem because he has no machines which have the problem, and is therefore unable to track down the source of the issue (error reports aren't enough; he'd actually need a machine with the issue to be able to work it out).
If you have knowledge of Python and actually manage to make a fix, you'd probably halve the number of incoming posts for this thread
(considering how many have complained of this error)
I'm working on a CTM map, and Importing some dungeons I designed earlier. I'm exporting from one map into another.
Four of my five dungeons I've completed import fine, but the fifth gives the following error:
I don't know how to import this file: Dungeon III - Blackspine Caverns.schematic
Error: LoadingError(('Multiple errors encountered',
NBTFormatError('Not an NBT file with a root TAG_Compound
(Found 31)',), IOError()'MCJavaLevel attempted for smaller
than 64 blocks cubed',)), <traveback object at 0x32CD0C38>
I'm not sure about that "Smaller than 64 blocks cubed" is about, the cave is massive.
It'd be much appreciated if anyone could explain this to me, even more so if someone has a solution.
(I ran a search of this topic, but didn't' find anything.)
Sigma_Phi - home of the long-winded answers to questions nobody asked.
And I am sure that the world editor that YOU made is soooo much better.
Please provide a link, and evidence of the joy it has brought to the Minecraft community.
How was that schematic file created? MCEdit is pretty picky about its schematics.
(Also, you didn't actually link the schematic. Just giving the name is kinda useless.)
The schematic file was created IN MCEdit. I'm using MCEdit to pull a dungeon from one map and drop it another.
And, excuse my stupid, but how would I like the schematic here?
Sigma_Phi - home of the long-winded answers to questions nobody asked.
id also be wiling to help with the whole intel problem, though if need someone to guide me through it, as i have no idea how to code or anything (like if someone without intel knows how to ect...)
I have check all through the forums and all I can find is 32bit.
And how I can allocate more ram to it?
I split the dungeon in half and imported the halves, and it worked. Go figure.
Well, thank you!
Sigma_Phi - home of the long-winded answers to questions nobody asked.
*facepalm*
This kind of thing is why I left.
https://github.com/downloads/Zap-12100/mcedit/MCEdit-0.1.1-1-g41ea.win-amd64.zip
You don't "allocate" RAM like you would with Minecraft, MCEdit manages its memory usage automatically. If you still run out of memory you're simply doing more than the program can handle.
That thing with the Nudge feature is intentional and it's been coded in as long as I can remember.
You'll have to learn to code, no other programmer will baby you. Thankfully if you've got the right mindset it's not too hard.
Start by downloading Python and playing around in the interpreter. Follow an online tutorial to make basic programs. I'm not going to link you to any of this - if you can't use Google to find things out for yourself programming won't be your forte.
btw is it OK that minecraft also crashes if i travel some chunks one way, because when i started playing it. everithing was fine. mc was littlebit laggy on my old mashine but still playable. but now it eats up all memory on my PC. On different PC's it just runs out of memory and ask to close it. It is not playable anymore.
I'm frustrated. Is it worth to try it make playable or it's just a waste of time?
ok i shall try, thanks for the nudge in the right direction