First of all, thank you for checking out, and thank you very much for your translation fixes! I've merged them, I'll review your suggestions here and commit a new version soon.
Wuzzy wrote:Intereting tool. It's nice to look up a schematic without opening Minetest and it seems useful to fix SMALL mistakes. However, larger edits are very inconvenient and time-consuming, I think [worldedit] + [schemedit] are much more efficient methods of editing.
Yes, exactly. It's main purpose is to convert other formats into MTS. The GUI editor is just an extra for small fixes (mostly to correct import problems), it was never intend to replace worldedit + schemedit.
Wuzzy wrote:I like the preview image feature.
Wuzzy wrote:The program fails if your schematic has a lot of nodes that the program doesn't know yet. It seems there is some kind of import feature, but I'm too lazy to use it. It's too much additional workload. Anyway, I think I'll keep this program.
What do you mean "program fails"? Is it throwing some kind of errors? I made it in a way that unknown nodes are added to the node palette automatically, so that you can use those without a technical name translation rule (obviously there's no node image for them and you can't change the node mapping in lack of translation rules).
Wuzzy wrote:Problems I found with the program:
- It becomes very slow for large schematics
Could be. I haven't optimized the GUI really, which means it does not cull nodes when it generates the surface caches (one for below, one for above and one for the currently edited layer). Good news is, once you have those caches, it works smoothly.
Wuzzy wrote:- The load file browser closes whenever you change directories
Never noticed that. I'll definitely take a closer look and see if I can reproduce this. You should only click once, double-click has a different handler (but if it closes the file browser it must be fixed).
Wuzzy wrote:- param2 only ranges from 0-31, not 0-255
That's intentional. MapNode
always masks getParam2, and the largest value is 31.
Wuzzy wrote:- Rotating the schematic overrides param2 of all nodes, irregardless of their paramtype2. This screws up all nodes that are not facedir nodes
This is a known issue. You can change param2 for those nodes with [shift]+[left] or [shift]+[right]. There's no way of knowing a node's paramtype2 outside of the game, and what's worse, there's no consistency among mods. For example "mcl_core:chest" could have one paramtype2, and it's corresponding "default:chest" could have something different (just an example).
Wuzzy wrote:- Unknown are never translucent and look broken when moving upwards in layers
That's right. I have tried translucent "unknown node" image, and it was even worse, ugly as hell :-(
Wuzzy wrote:- Deleting or adding X or Z layer does nothing
Are you sure? Were you at the middle of a structure or at the side? Those use the current cursor position, so I suggest to use keyboard shortcuts and not the icons on the left. This is definitely an UI issue, I'll have to figure out something.
Wuzzy wrote:- Rotation of ladder is wrong
Thanks. I'll have to replace the node image.
Wuzzy wrote:- Window title does not update when loading a different schematic from the load menu
Thanks, this is a bug, I'll fix.
Wuzzy wrote:- Many node preview images are incorrect
Incorrect how? Could you ellaborate please so that I can fix the preview?
Wuzzy wrote:- default:snow is confused with default:snowblock
Yeah, could be. Getting the correct node for all game+mod variants is difficult. I'll fix.
Wuzzy wrote:- Rail can be rotated (it is not rotatable, param2 is meaningless)
In general the editor does not know how a node's param2 is interpreted, it just sets param2 value. But if param2 is meaningless for the engine, then this isn't an issue I suppose.
Wuzzy wrote:Bad UI/UX:
- No way to see or set node probability
That's right. Node probability is not changeable for now. This is a missing feature.
Wuzzy wrote:- It's not clear what the node's param2 value is
Exactly. I don't know either. So the editor allows to set it's value, and might display the result incorrectly. Here I though it would be better to allow changing of param2 and saving into files even if some displayed incorrectly in the editor, rather than disallow (previous versions only allowed param2 values that had node images, I've removed this constraint).
Wuzzy wrote:- Can't start program with no file selected
This is not a bug, it's a feature :-) The editor is primarily a command line tool, so you have to run it in a Terminal. Without arguments, it displays all the options. Providing a GUI editor is just its secondary goal.
Wuzzy wrote:- I find it very tedious to move the mouse. Even at 200% zoom I often misclick. Maybe this is because the mouse cursor is invisible
That's correct, zooming is done in run-time, therefore it might lag when you use big structures. There's a simple solution, press [A]. This will toggle the display of below and above layers, and scaling only the current layer is pretty fast even for large structures (there's an X and Z culling, and by turning off below and above, you eliminate the need of iterating through Y). First version displayed the mouse cursor, and that was just annoying, I couldn't see what's the node beneath, that's why I turned it off.
Wuzzy wrote:- Editing large parts of the schematic also feels quite tedious. It's not fun. I think [worldedit] + [schemedit] is still my favourite method of editing schematics
This editor's main goal is to import other schematic formats, and allow you to do small fixes. However if you have some ideas how to make the UI better, I'm open to suggestions.
Wuzzy wrote:Other stuff:
- The preview looks kinda ugly, the outlines are pretty jagged but its better than nothing.
- Shading of preview is too extreme. I would recommend flat shading for simplicity
Preview uses the simplest orthographic projection. Shading is the only thing that provides some sense of depth. In the first version there was no shading at all, and I was unable to tell from the preview which part of the structure is where. I've noticed this in mtsconv, and I've implemented a simple shading in mtsedit too.
Wuzzy wrote:Mising features:
- Toggle force node placement
That's not missing. You can toggle force node placement for non-air nodes with [D] (both [F] and [P] shortcut was already taken). For air nodes, the force placement bit is automatically calculated by detecting rooms in the structure.
Wuzzy wrote:- Per-node probability
Yep, this is missing.
Wuzzy wrote:- “New file” button
Wuzzy wrote:- Layer probability does not show raw value, which leads to loss of precision
Yeah, I was thinking about this. But my boys had issues with raw values, so I decided to display percentage. The value changed and stored in MTS files is correct though, full precision, it's only converted to percentage on screen. I can revert to raw value in no time.
Wuzzy wrote:- Display/set schematic boundaries
This is most definitely never gonna happen. There's no such thing schematic boundaries. You are free to edit anywhere, and the bounding box is calculated automatically when you save the structure.
Wuzzy wrote:- Node pipette
This is implemented when you delete a node with [Backspace]. You can place it back right away with [Space], but having a separate pipette tool is a good idea!
Wuzzy wrote:Nice to have:
- Add toggable node overlays:
-- param2: Display param2 number on all nodes (except 0)
Wuzzy wrote:-- probability: Display probability number on all nodes (except 100%)
I think I'll postpone this as you can't edit probability per node as of yet.
Wuzzy wrote:- A "full preview" mode. If enabled, the full schematic is visible at once.
You can zoom out, but having a non-editable full preview for the entire structure sounds good.
Wuzzy wrote:- A "random preview" mode. Same as full preview, but with node/layer probability applied. Would be very useful to test out the randomness of your schematic. Due to the nature of this mode, this might only be a “view-only” mode, i.e. no editing possible
I agree this would be nice, however I'm afraid this would made the interface too complex.
You are awesome man! This is great!
Wuzzy wrote:I recommend against using the prefix “biome:” for biome-specific nodes, it's likely to cause a name collision sooner or later. How about “_mtsedit_biome:” instead?
No. Biomes are Minetest engine entities along with their properties, biome:node_top has nothing to do with my editor.
Wuzzy wrote:That's because the documentation of param2 is in lua_api.txt.
Not quite. The lua_api.txt has some more info, granted, but I think this should be documented properly. I've also read lots of forum topics about facedir, this seems to be a constant issue unfortunately.
Wuzzy wrote:param2 is between 0-255 and its meaning depends on the node definition (paramtype2). Look for “param2” and “paramtype2” in lua_api.txt. It's not only for rotation. And yes, you need to support the full range 0-255 of param2, not only 0-31. Also, param2 is usually displayed in decimal form, not hexadecimal.
Supporting param2 for non-rotational types is out of the scope I'm afraid. I've talked about this with @Sokomine. Besides, MapNode masks param2 to 0-31, so higher values are only relevant inside the engine, but thankfully not in schematic files.
If you like to play around with param2 and see how it works, try out my DevTest game (viewtopic.php?f=50&t=24030
). Enable debug mode, place the various test nodes and use the param2 tool on them and see what happens.
This is exactly what I have done so far :-) But not with all the nodes, that would take more time than I have. :-(
Wuzzy wrote:That's a really weird hack. Why does ground level even need to be stored?
To avoid that even dirtier hacks like you've used with the igloo. Having two files for a structure is unmaintainable on the long run. This feature is needed for all structures that has underground part. Like the pyramid, well, etc. If you are in a doubt, read the viewtopic.php?f=7&t=23858
topic, several modders agree this is needed, and you can also see other hacks to this missing feature.
Wuzzy wrote:Anyway: This hack is unreliable for obiouvs reasons. I would save the ground level somewhere else.
Yeah, the best would be to store 4 ints in the header: width, height, depth and ground.
Wuzzy wrote:Maybe the node name table can be abused for this. Adding a fake node name like “_mtsedit_ground:X” with X being the ground level. Minetest will discard is since this node is not actually being placed, but MTSEdit can read it just fine. It should also be possible to set no ground level at all.
Not good, the MT engine would complain about the node, I've tried. If nothing else, it would display a red error message about it's texture. Since MapNode uses "getParam2() & 0x1F" in the code, we are free to use param2 bit for this, no errors reported (but I agree this is not an optimal solution).
Wuzzy wrote:But in general, I dislike introducing any hacks like that.
I couldn't agree more. Ground level should be added to the MTS header, but that would break compatibility with existing files, so this change should bump the file version.