Jump to content

Hal's Prefab Editor


HAL9000

Recommended Posts

[QUOTE=Wsiegel;91471]Okay... you asked for it...lol, Not sure if these are easy or hard to do.. so I will list some and you can comment. 1. A handy feature would be to have the "blocks in layer" list on the lower right side of the screen selectable. not just showing me the blocks by double clicking on it.. but to be able to select that block for my brush by right clicking on it. 2. A mirror function left to right, right to left, top to bottom, bottom to top. ( single layer - all layers ) This could mirror from the center 1/2. If odd number mirror from/to the center odd row/column 3. Possibly a multi-thread search with a comma or something so we can search for like item that are called out differently.. IE slope and wedge .. search by "slope, wedge" or "light, lamp" Not sure if there is an easier way to get the list of the similar shape blocks that are called out differently, but at least i can search them by multiple names. 4 Display an image with tag numbers of the decals on the right side of the screen, ( this can be turned on and off with a check box ) Then when placing decals you don't need to switch back and forth to pick and choose decals from a cheat sheet. I do love it that you can copy and paste blocks with decals. :) Well that's enough for now. Cheers mate[/QUOTE] All suggestions welcome. Not all suggestions will be added :D But those are added to the to-do list. The image on block select might not make the cut though as I don't really mess with the asset files and managing all the images when it changes could get annoying. But Blood, if you're reading, I'm open to suggestions if you know an easy way? Multi search is now added in the next version. Just separate with a comma e.g. "slope,wedge" When searching, would it be easier if the results were alphabetical or as they are?
Link to comment
Share on other sites

[QUOTE=HAL9000;91334]With you mentioning that it couldn't auto-update the Assembly-CSharp.dll file it's sounding like a permissions issue. Did it display an error when it failed to auto-update? Do you have custom permissions on your game folders? Is the user you're running as an administrator? And just to clarify, when you're manually updating the Assembly-CSharp.dll file that is the only file you're moving? Don't replace the UnityEngine.dll or any of the other files. Can you verify the permissions on the Assembly-CSharp.dll file? If you're not sure how to do this here is a [URL="http://www.wikihow.com/Change-File-Permissions-on-Windows-7"]link[/URL]. Can you verify that the username you're using has read and write permissions on the file? Or send me a screenshot of what's in the security tab?[/QUOTE] Yes i agree, it sounds like a permissions issue. Do you have a firewall? If so is the prefab editor exe added to the exclusions list? Do you have an Antivirus that has a built in firewall?
Link to comment
Share on other sites

[QUOTE=Wsiegel;91471]...to have the "blocks in layer" list on the lower right side of the screen selectable... to be able to select that block for my brush by right clicking on it.[/QUOTE] I totally support this... and take it off my list of improvements. [QUOTE=Wsiegel;91471] A mirror function left to right, right to left, top to bottom, bottom to top. [/QUOTE] Yea, a mirror function! Totally needed. Why have'nt I thought about that? [QUOTE=Wsiegel;91471] a multi-thread search with a comma or something so we can search for like item that are called out differently.. [/QUOTE] A way to categorize them could also do the trick but somehow I don't think HAL would be happy to adapt the categories every time the pimps decide to change objects or materials. Maybe the best approach is to provide a simple tool to create/delete categories yourself and move items around (like with with drag and drop) [QUOTE=Wsiegel;91471] I really could use is an image viewer.. when you select a block, display the flat image, similar to the way Blood's recipe editor has [/QUOTE] Indeed a preview image of the material or something like it would be very helpful. To compensate the absence of a object/material preview, I made me a prefab with every block available built, so I can look around and choose the right material before building. Could'nt the picture preview also be implemented somehow as a feature to be configured and maintained by the users themself? Like they pick the color for the material themself, why not let them import pictures for the objects and materials themself? This would be a good job done by the community with tools like UAE. I am sure after a short while someone will come up with a package to download and import for everyone as long as there is someone interested. With such an import feature, the community could provide images of every material and a fitting category label and do updates to it in case the game changes. At least a import of pictures for different categories would improve the handling of the programm for me a lot.
Link to comment
Share on other sites

@ Tohuwabohu, I open and use Blood's recipe editor, he has a tab for block preview.. or Image gallery.. it shows all the block and updates quickly when the Pimps change things.. you might want to check it out if you haven't
Link to comment
Share on other sites

[QUOTE=HAL9000;91481] But those are added to the to-do list. The image on block select might not make the cut though as I don't really mess with the asset files and managing all the images when it changes could get annoying. But Blood, if you're reading, I'm open to suggestions if you know an easy way? [/QUOTE] I would leave this to the community! Define the file format and its properties for an import of pictures and other additional block and entity information by the user himself! This could be done for every single block/entity (file import) or based on userdefined categories (could be something for a special page inside preferences. That way we would be able to have materials that we use often in a project moved to a custom-labeled category on top of the list and dont have to scroll though it, searching. [QUOTE=HAL9000;91481] Multi search is now added in the next version. Just separate with a comma e.g. "slope,wedge" [/QUOTE] Cool. This will come in soo handy. [QUOTE=HAL9000;91481] When searching, would it be easier if the results were alphabetical or as they are?[/QUOTE] For me ... alphabetically., To be honest, I was not able to see the logic until now, in what the results are displayed, at the moment.
Link to comment
Share on other sites

[QUOTE=Wsiegel;91547]@ Tohuwabohu, I open and use Blood's recipe editor, he has a tab for block preview.. or Image gallery.. it shows all the block and updates quickly when the Pimps change things.. you might want to check it out if you haven't[/QUOTE] Okay ima check it out. Sure, something that exports the correct images automatically for all the blocks would be great, but it also sounds like a really tough job for HAL to do, thats a lot of time to invest for a non-core feature... but we will see.
Link to comment
Share on other sites

[QUOTE=HAL9000;91334]Ok Sythius, thanks for the update. With you mentioning that it couldn't auto-update the Assembly-CSharp.dll file it's sounding like a permissions issue. Did it display an error when it failed to auto-update? Do you have custom permissions on your game folders? Is the user you're running as an administrator? And just to clarify, when you're manually updating the Assembly-CSharp.dll file that is the only file you're moving? Don't replace the UnityEngine.dll or any of the other files. Can you verify the permissions on the Assembly-CSharp.dll file? If you're not sure how to do this here is a [URL="http://www.wikihow.com/Change-File-Permissions-on-Windows-7"]link[/URL]. Can you verify that the username you're using has read and write permissions on the file? Or send me a screenshot of what's in the security tab? Hal[/QUOTE] There's only one user set on this computer as its my personal gaming PC, full admin, no custom permissions. I only copied the Assembly file from the .zip folder to replace in in the game directory and editor directory, since it didn't replace them with the manual update. It wasn't a system error, the updater did say something about that version not having exporting included or something so the .dll wouldn't be updated. I hadn't gotten that message until I totally reinstalled 7DTD and the editor, and I've never had any issue with the editor before. I'm 100% sure I have full access read/write to all files on the drive. If no one else is having issues I'm totally stumped.
Link to comment
Share on other sites

Myzaar... Do not change the Dll. If you are using an older link for the editor.. simply unzip it into a directory and run it without changing any of the dll's Run the editor and it should go out and search for an update and change the dll to the newest one ( not the one in the zip file ).
Link to comment
Share on other sites

Ok, by some miracle I got it working after reinstalling both again. I didn't do anything different that I know of. When exporting a prefab now, I save it, then go to place it in game and it gives me an error "end tag cannot appear in this state. Line 1017, position 3." and the next line "Object reference not set to an instance of an object." both appear in red in the console and the prefabs dont load. The editor also drops an error when I load the .TTS file after it's been saved from an export the second time, although I can still see the blocks configured properly in the editor. Any idea what's going on?
Link to comment
Share on other sites

It's not letting me export anymore either, and the three i had exported upon first loading say 'end tag cannot appear in this state. Line 1017, position 3.' even when the export is loaded in the editor... EDIT: Ok, while I don't know why my exporting isn't working, I fixed the end tag error
Link to comment
Share on other sites

@Wsiegel and @Tohuwabohu Thanks for the suggestions, they're added to the list (and the easy ones are already done). I'm in the middle of writing a new mod but all the code is bundled together so when I release the new mod preview you'll get the latest updates in the editor too. @Myzaar What errors are you still getting? Just the export feature? Do the other commands work? Like "bbb jet" or "bbb tp 0 0 0"? If you're still having trouble with your exports can you post the files? And any TTS that's you're having issues with too. Cheers, Hal
Link to comment
Share on other sites

Forgot to mention about the image viewer... Aussie is working on a 3D block viewer with orientations (and possibly even a prefab viewer! Nice eh?). He has said he's hoping to support being able to control the app externally and has given permission for me to use it in my editor to show people what the blocks are / how the orientations work. So that may be the best solution for people.
Link to comment
Share on other sites

[QUOTE=HAL9000;91672]Forgot to mention about the image viewer... Aussie is working on a 3D block viewer with orientations (and possibly even a prefab viewer! Nice eh?). He has said he's hoping to support being able to control the app externally and has given permission for me to use it in my editor to show people what the blocks are / how the orientations work. So that may be the best solution for people.[/QUOTE] I was secretly hoping that would happen. thanks for sharing. I wont hold you to that, but nice to know Aussie is willing to make it externally supported. +1 to both of you.
Link to comment
Share on other sites

@HAL Wow. Sounds superb. A 3D block viewer, with the acutal textures, and a preview for the direction the block is currently facing, will be even more than we asked for. :surprise: This kind of basic interoperability between your PrefabEditor, maybe UAE, the recipe editor and others like this preview tool from Aussie, could easily be the key to a really remarkable community-driven modding toolset in the future. I gotta admit, to think about it, gets me kindof excited.
Link to comment
Share on other sites

Even though i am trying to copy the textures exactly, The colours of the texture sometimes don't look correct, as it depends on the time of day I take an image in-game. I generally set the time to 12 noon, by using the st 20000 command from the console, prior to taking the snapshot. @ Hal I am almost ready to release another update to the guide, and will be adding the command line to it , to allow the opening from within another program. I have set the block/ sub block numbers , so the blocks can be selected, regardless of name. Also had to add the rotation in the X direction, as one block (wedge60EndShingleAsphalt-Blue-Green-White-Yellow-Tan-Burnt) needed the extra rotation. Is slow going with work commitments at the moment. Got around the C4D-RipTide plugin problem by changing my system date, so it doesn't time out, then leave C4D running for days, and change the date back... A lot of the blocks models are just copies, with different textures on the faces, so I hope to get more done soon. Will Update the guide soon. Aussiewombat
Link to comment
Share on other sites

[QUOTE=AussieWombat;91834]Even though i am trying to copy the textures exactly, The colours of the texture sometimes don't look correct, as it depends on the time of day I take an image in-game. I generally set the time to 12 noon, by using the st 20000 command from the console, prior to taking the snapshot. @ Hal I am almost ready to release another update to the guide, and will be adding the command line to it , to allow the opening from within another program. I have set the block/ sub block numbers , so the blocks can be selected, regardless of name. Also had to add the rotation in the X direction, as one block (wedge60EndShingleAsphalt-Blue-Green-White-Yellow-Tan-Burnt) needed the extra rotation. Is slow going with work commitments at the moment. Got around the C4D-RipTide plugin problem by changing my system date, so it doesn't time out, then leave C4D running for days, and change the date back... A lot of the blocks models are just copies, with different textures on the faces, so I hope to get more done soon. Will Update the guide soon. Aussiewombat[/QUOTE] Great news Aussie! Looking forward to your next release. Glad you got a workaround for the plugin. Is there no way to get the textures en-mass from the asset file? Sounds like a lot of time needed to get all the textures out otherwise. Maybe a community effort to help with the time consuming bits? Hal
Link to comment
Share on other sites

GUI Idea Plus Additional Functions Alright, this took longer than I thought. Wanted to throw in some extra ideas of my own. [B]Backup Manager[/B] Save Z: Store Z coordinate for isolating a claim to make a prefab. If I recall correctly, this feature exists in land claim console. It'd be handy to have it here too. At least as a toggleable option. Omit Blocks on Save: Define which blocks to be replaced with Air. Can be used to omit terrain for prefab structures and prevent location dependency based on terrain. [B]Prefab Editor[/B] Grid Style: Option to change grid to dotted line or invisible. Can be useful for viewing large prefabs while zoomed out. Is it at all possible to emulate the structural integrity algorithm? If so, showing integrity of blocks by color as its own layer would be very helpful in quickly finding good and bad hotspots (traps vs structures that need to be walkable) And here's the GUI idea. It attempts to have everything present. I tried to maintain all features. They're either moved or renamed. Of course, there are additional options. [IMG]http://sdtd.daveledev.com/preview01.png[/IMG] [url]http://sdtd.daveledev.com/preview01.png[/url] In the title bar [MEM] and [DISK] could be used to denote how a file was opened. A status bar is added at the bottom and gives coordinate information as well as which tool is selected. Block Color Palette: A favorites toolbar of commonly used blocks. Works just like it would in MS Paint. Exception: instead of color selection, block selection. A primary and secondary block are available and swappable. Dragging from the primary/secondary to a slot on the palette adds the block to the palette. Under General Settings, most options are recognized. Two additional buttons, the up and down arrows, select the bottom-most and the top-most layer respectively. Under Display are options to toggle texture, decal, color,or value. Here's how it could work: Block Texture: show block image instead of the editor's color. Block decal works as normal. Color for Damage, Rotation, and Integrity work similarly. Instead of letters like DW, it uses a customizable color palette to visually represent damage and orientation. Integrity (if it can be integrated) uses the same colors as Damage. Value for the previous three displays just that: if a block has a damage value of 3, it'll show 3. For rotation, 0 = Down West, 1 = Down North, 2 = Down East, and so on. Reset functions as normal; it replaces "Reset on layer change". "Drawing" is completely redesigned. All and None function as normal. User uses the selection box below. The selection box shows color, name, and block ID information as well as quantity on the current layer. This box could also be used to change block color. Drawing Tools: (LMB=Left Mouse Button; RMB=Right Mouse Button) Pencil- LMB: Draw per block with primary block RMB: Sample block Shift + LMB: Draw line from last coordinate to current coordinate Ctrl + LMB: Draw per block with secondary block Shift + Ctrl + LMB: Draw per block with random, alternating primary and secondary block Eraser- LMB: Erase per block RMB: Erase all connecting like blocks of current coordinate Shift + RMB: Erase all like blocks of current coordinate Shift + LMB: Erase line from last coordinate to current coordinate Ctrl + LMB: Erase per block but ignore primary block Shift + Ctrl + LMB: Erase per block but ignore secondary block Fill- LMB: Fill all connecting like blocks of current coordinate with primary block RMB: Fill all connecting like blocks of current coordinate with secondary block Shift + LMB: Fill all but connecting like blocks of current coordinate with primary block Shift + RMB: Fill all but connecting like blocks of current coordinate with secondary block Ctrl + LMB: Fill all like blocks of current coordinate with primary block Ctrl + RMB: Fill all like blocks of current coordinate with secondary block Rectangle- LMB: Draw hollow from current to final coordinate with primary block RMB: Sample block Shift + LMB: Draw filled from current to final coordinate with primary block Ctrl + LMB: Draw hollow from current to final coordinate with secondary block Shift + Ctrl + LMB: Draw filled from current to final coordinate with secondary block Ellipse- LMB: Draw hollow from current to final coordinate with primary block RMB: Sample block Shift + LMB: Draw filled from current to final coordinate with primary block Ctrl + LMB: Draw hollow from current to final coordinate with secondary block Shift + Ctrl + LMB: Draw filled from current to final coordinate with secondary block (icons were ripped from MS Paint)
Link to comment
Share on other sites

Wow Hiyoto, that's a lot of ideas! I like the layout. It looks a lot more organised. And uses the space available a lot better than at present. The drawing functions are linked to the keyboard shortcuts (and you know where that is on my to-do list :D). Not sure about the fill option though as without an undo button it can go wrong very quickly. But drawing filled/hollow rectangles is something I've wanted to add for a while. I'll add it all to my to-do list, thanks. Hal --edit--- On an unrelated note - have you guys seen the random world generation stuff posted by Kinyajuu? If not, check it out [URL="http://kinyajuu.imgur.com/"]here[/URL] - awsome sause.
Link to comment
Share on other sites

So... Pretty! I forgot to add for Rotation under Display: if value is unchecked it could default to the regular method of letter directions. I could probably also add a selection and a spyglass icon to eliminate the need to have to switch modes entirely.
Link to comment
Share on other sites

[QUOTE=HAL9000;92051] On an unrelated note - have you guys seen the random world generation stuff posted by Kinyajuu? If not, check it out [URL="http://kinyajuu.imgur.com/"]here[/URL] - awsome sause.[/QUOTE] Very nice indeed, must send congrats to Kinyajuu.. AussieWombat
Link to comment
Share on other sites

Anyone know how to place a structure underground and have the terrain generate above it like it's not there, but the building not filled with earth? If i copy air blocks it removes all the terrain above it, and yes i've removed all layers above the prefab in the editor, and selecting 'Allow Top Soil' doesn't seem to do anything with air blocks checked or unchecked. If Copy Air blocks isn't checked the structure is filled with rock. I'm sure someone's done this before so how do i go about this?
Link to comment
Share on other sites

[QUOTE=Myzaar;92109]Anyone know how to place a structure underground and have the terrain generate above it like it's not there, but the building not filled with earth? If i copy air blocks it removes all the terrain above it, and yes i've removed all layers above the prefab in the editor, and selecting 'Allow Top Soil' doesn't seem to do anything with air blocks checked or unchecked. If Copy Air blocks isn't checked the structure is filled with rock. I'm sure someone's done this before so how do i go about this?[/QUOTE] As long as your upper most layer is below the ground layer it should generate properly. And with copy air blocks to remove rock from inside. You can see this in my Diersville sewers and the Gravetown transit system. By the way make sure you clear the region after each attempt to change your settings. If your upper layer is equal or higher than the ground layer, you have to re-create the ground layer in your prefab. There is no "null" block to replace air block underground, either all air blocks in your prefab or none.
Link to comment
Share on other sites

It's below the ground layer, at the lowest point its only about two layers below, and the highest probably 35 layers below. I delete the old region each time but i either get it totally filled in or the ground is cut away and I'm not sure why...
Link to comment
Share on other sites

[QUOTE=Myzaar;92145]It's below the ground layer, at the lowest point its only about two layers below, and the highest probably 35 layers below. I delete the old region each time but i either get it totally filled in or the ground is cut away and I'm not sure why...[/QUOTE] I'm heading to bed now.. but if you want to PM me the tts file and the prefab line I can take a look at it for you in the morning.
Link to comment
Share on other sites

[QUOTE=Myzaar;92145]It's below the ground layer, at the lowest point its only about two layers below, and the highest probably 35 layers below. I delete the old region each time but i either get it totally filled in or the ground is cut away and I'm not sure why...[/QUOTE] Also just so we are on the same page.. In the editor. layer 0 is the bottom most layer and equal to the layer ( middle ) number in the prefabs.xml file. Layer 1 is above that going upward... It works from the bottom up not from the top down. So you upper most layer number needs to be below the surface. You can calculate it by ( Top Most Layer Number + Prefabs.xml layer position ( middle number ) ) This needs to be below the surface number. Also if you use the lp command to find the height number of the ground, you have to subtract 1 as you are standing above the ground.
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...