Jump to content
Pille

Prefab Editor (Alpha)

Recommended Posts

After rereading your text and playing with Hal's editor, I am starting to think that all you want is some kind of shortcut (or mouse button) for the function of the block picker tool (see screenshot bellow). Am I right?

 

6oXcxtW.png

 

Yeah pretty much. The pencil mode is where I'm spending most of my time, the things that were a bit tiresome to draw in hals are easy with your brushes and I can switch over to select mode with a hot key whenever it's needed. When I'm skimming through layers and spot something that needs fixing I either select air to erase the mistake or whatever the block is directly to replace, two clicks and I'm skimming down the layers again.

 

Not had to remove layers yet but had no issues doing rows/columns, Hals' approach was pretty useful for that as every fresh extract will need trimming above and below, however the days of having to extract are limited for me now as I'm finding it much easier to make a base build in the editor to freshen up in an empty SP world with the games editor mode enabled with the bbb commands.

Share this post


Link to post
Share on other sites

@Batman

YES! Please, maybe bind it to middle mouse button? Or make it configurable? It would save alot of mouse movement! Excellent tool by the way, looking forward to seeing it progress.

 

I am going to bind it to the middle mouse button in the next version and maybe add user defined tools.... :)

 

 

 

@Guppycur

As far as removing layers, I think you're taking a gui approach to what would be easier (for the end user) as a command approach. "Remove Layers", then choose what range of layers to remove.

 

With columns and rows, Hals' function key method was pretty damn good as well.

 

(for some reason the editor no longer starts, although it did yesterday... I think windows is jacking with me)

 

Since you're "out of the game" I should ignore your feedback. ;p

 

I think there should be both, a gui based approach and and a command. Sometimes it's useful to see which layers will be removed. So there will be new text fields (columns and rows from and to) in the one of the next updates and a new auto-trim button which deletes outer air layers. Btw. it was easy to remove too many rows or columns using Hals' function key method and then you couldn't undo your actions. This was one of the very few things that I didn't like too much.

 

Just a little hint: What a layer is (or a column and row) depends on the selected view. So if the top view is selected, a layer is a horizontal rectangle with a height of 1 block. If you're using one of the side views then you have vertical layers. The consequence being that you cannot remove the needless (horizontal) layers above your prefab if the top view is selected. I admit that can be confusing.^^

 

(for some reason the editor no longer starts, although it did yesterday... I think windows is jacking with me)

Do you get any error messages and have you tried downloading the editor again?

 

 

@Slaan

Not had to remove layers yet but had no issues doing rows/columns, Hals' approach was pretty useful for that as every fresh extract will need trimming above and below, however the days of having to extract are limited for me now as I'm finding it much easier to make a base build in the editor to freshen up in an empty SP world with the games editor mode enabled with the bbb commands.

 

What's an empty SP world? A totally flat map? Can you give me a link / explanation how to do?

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites

Windows was being an ass. I've got the editor installed in two places now, each with identical files, but only one starts. I entirely blame Windows 10, ever since the "creator" update or whatever, it's been a total d1ckwad.

 

...he is likely referring to this:

 

https://7daystodie.com/forums/showthread.php?47459-Unlocking-In-Game-Prefab-Editor-(Terrain-Tools)-dll-mod&highlight=unlocked

 

Or by changing the mixer setting to make a flat world:

 

<property name="scale" value="255"/> //changing 255 to 1 makes it flat if I recall

Edited by Guppycur (see edit history)

Share this post


Link to post
Share on other sites

I've installed this now as well, here's some feedback:

 

Tooltips.

 

I have made copies of a couple of prefabs and use them as terrain decoration. Now I want to remove lootcontainers from these prefabs. To find them, I have to click every block and get the info what it is. It should show me what it is on a simple mouseover.

 

Editing has already been mentioned: Having to click back and forth between the arrow-button and the pen-button is very tedious.

 

It would be great to have a function that will highlight all blocks with a certain class. Or (potentially better) have certain colors for certain classes, like "loot" are different shades of green, "door" shades of blue, etc.

 

A "replace block ID x with block ID y" function has proven to be very (extremely) useful.

 

The program also needs an "undo"-function.

 

I accidently tried to open an .xml-file instead of the .tts: Program crashed.

 

When I open the xml-file produced by the program when I save the prefab with notepad under windows 7, the content is in one line and has no line-breaks. It is nicely formated in Notepad++.

 

"Square". ;-P

 

Other than that, what I've tested works fine, the changes I made show up, painting works. If you improve the usability, it's going to be a fine program. The side-view-option is a nice touch.

Share this post


Link to post
Share on other sites

I have made copies of a couple of prefabs and use them as terrain decoration. Now I want to remove lootcontainers from these prefabs. To find them, I have to click every block and get the info what it is. It should show me what it is on a simple mouseover.

 

It's already there. Just have a look at the title bar of the program or at the info tab. ;)

 

Editing has already been mentioned: Having to click back and forth between the arrow-button and the pen-button is very tedious.

Seems to be very important to the users. Soon...^^

 

 

It would be great to have a function that will highlight all blocks with a certain class. Or (potentially better) have certain colors for certain classes, like "loot" are different shades of green, "door" shades of blue, etc.

 

I am not sure if that works if there are too many blocks in one class. I had a similar problem using the editor to find sleeper blocks. So it need to be fixed. It's probably the easiest to tune the block selection tool (see bellow). Atm it's based on block ids and it doesn't highlights blocks but selects them. A more powerful version (with more options) of this thing could do the job.

 

v3AdCLk.png

 

The program also needs an "undo"-function.

It's relatively hard to implement since you can change or even delete each block within one step. So if you're working with a very large prefabs, you get memory issues. I am already working on the problem. Don't know how long that will take.

 

When I open the xml-file produced by the program when I save the prefab with notepad under windows 7, the content is in one line and has no line-breaks. It is nicely formated in Notepad++.

Mhh I don't know, sounds like a minor bug related to Qt (the programming framework that I use). So that will be fixed at some point (if I don't forget your bug report). ;D

 

I accidently tried to open an .xml-file instead of the .tts: Program crashed.

There is a file extension filter in the save and load dialog. You shouldn't be able to do that.

 

"Square". ;-P

I don't get it. What? ^^

 

Thanks for the detailed feedback!

 

 

 

@Guppycur

Thanks. Looks very useful.

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites
It's already there. Just have a look at the title bar of the program or at the info tab. :)

 

Nice. If you could add the block-id to the title bar, that would be perfect. I also did "find" the tabs in the edit window now. I also found the replace-function, obviously a must-have. Replacing blocks for all prefabs in a folder would be helpful too, for example in my situation, where I want to replace all loot-containers for a couple of prefabs. It also made me think about replacing all sleepers with the "idle"-version, which I assume is a standing sleeper, that should be the fastest to attack, as it does not have to get up first.

 

I am not sure if that works if there are too many blocks in one class.

 

I don't know how many "too many" are, but in most cases, which is actually whenever a block has a class-property, there are not that many of a class. I guess the largest number would be "loot". It's just a convenience thing, though.

 

Ways to find certain blocks in a prefab are always good, not just the class, but also, for example, rotation, material, shape, and so on. A "find" or "highlight"-tab in the edit window would be great, with an interface with checkboxes and drop downs about what you want to find. Consider adding that to the bottom of your todo-list.

 

It's relatively hard to implement since you can change or even delete each block within one step. So if you're working with a very large prefab, you get memory issues. I am already working on the problem.
Every bit helps, if it would at least undo a single misclick, that would already be a good start.

 

sounds like a minor bug
I'd assume it's mostly a bug in notepad, I had that issue before with files, seems like there are two ways to indicate a line break and notepad only knows one.

 

There is a file extension filter in the save and load dialog. You shouldn't be able to do that.
I copied the filename over from the biomes.xml into the file open dialoge and the .mesh, the .xml and the .tss were suggested. I misclicked. It's obviously not the biggest of deals, since one would only open a new prefab when the one they worked on before is saved. But... A flaw is a flaw is a flaw, right.

 

I don't get it. What? ^^
Brush size, Density, Circle and "Square".

 

One more thing: The list of textures in the edit window is very small. Would be nice if it were bigger, a pop out maybe.

Share this post


Link to post
Share on other sites

Just to be clear, this doesn't appear to pull from the actual blocks.xml...am I correct in this?

Share this post


Link to post
Share on other sites

No, this was true for older versions of the editor. The current release reads the blocks.xml from your 7days directory.

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites

Alrighty, i

'll try solme reinstalls!.

 

And it works. woot.

 

Is there a way to see what blocks are in each layer besides clicking on them individually?

Edited by h0tr0d (see edit history)

Share this post


Link to post
Share on other sites

Mhh did you change the 7days directory? I made a test and added a new block to my xml (C:\Program Files (x86)\Steam\steamapps\common\7 Days To Die\Data\Config\blocks.xml) and it worked. Which xml does the editor read?

 

 

Edit:

Ok, strange error. Hopefully not my fault.^^

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites

 

Is there a way to see what blocks are in each layer besides clicking on them individually?

 

No, that's one of those important features which is not implemented yet.^^ You could select all block of the layer. Selected blocks are shown in the list above the views (see screenshot bellow) but that's not very comfortable. So you have to wait till I program this feature.

 

It's an alpha. ;)

 

v3AdCLk.png

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites

hi Pille

 

finally i had the time to check out ur editor. Very nice tool.

 

Can u add a function that do Block-ID-Replacements to the whole prefabs-folder ???

I have to make changes on Block-Id's always to about 150(+) prefabs. So i would really appreciate it when the editor had a function to do a block-change to all prefabs with just one click.

Hal called it global-functions in his editor.

 

thx ahead

Mag

Share this post


Link to post
Share on other sites

A new update is out. Some details about the new redo and undo functions:

 

The length of the action stack is limited to 10 actions. So you can undo 10 actions / go 10 steps back (maximum).

 

There is also a limit for the amount of changes: Undo doesn't work if you change more than ~1 million block properties (64 bit) (or ~250.000 for 32 bit) at once (within one single action). Properties are block ids, rotations, damage,... etc.

 

The following tools / buttons aren't included in redo/undo:

- add rows, add columns, remove rows, remove columns, shift blocks, advanced block replacing, replace layers

 

Using these buttons (or hitting the limit of ~1 mio. or 0.25 mio.) will reset the undo stack (deletes all saved data).

 

 

 

@Magoli

Yes, that shouldn't be difficult to implement. However, I don't have much time atm but I'll try to put it in the next release (maybe on monday, if you can wait ;) ). The load and save methods are inefficient, so my function will be slower than Hal's. I hope you don't care.^^

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites

Yes - thx u very much :)

 

ofc I will wait for this function and I dont care if it takes 5mins or 5hours processingtime then.

Mainthing is that I will be able to do it.

 

Its because the 2 Loot-corpses they had removed in a16. I want them to be replaced with sleeper-Blocks in A16 via ur editor.

(before I will pre-change them to any placeholder-block that is free (with Hal's)

and then after A15-A16 conversion i want to change them to sleeper-Blocks.

 

Thats my plan for adding sleepers to the COMPOPACK-prefabs.

U think this is possible ???

Share this post


Link to post
Share on other sites

Yay found the thread.

 

Looking forward to testing this.

 

I have a LOT of prefabs to remake for A16. =S

Share this post


Link to post
Share on other sites

@LuckyStar

I hope you can get used to the new editor and find everything you need (there are a few missing features in the current release, e.g. there is no entity spawning and no efficient way to find blocks).

 

@Magoli

Yes, but adding sleeper volumes to 150+ xml files would but very annoying and time-consuming. So we have to automatize this procedure. The problem is that I am still looking for someone who is able to explain to me how the sleeper volume system works.^^

 

Edit:

The next update is available. You find the new function in "tools tab" -> "Advanced" -> "Replace (Prefabs in folder...)". Just fill in the first line if you want to replace a block id:

 

zE3lMAL.png

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites

Hey Pille, new to the whole prefab creation thing so sorry for the noob question here but...

 

what do I need to do to export a prefab from in game and into the editor for saving?

 

Thanks!

-Bear

Share this post


Link to post
Share on other sites
Hey Pille, new to the whole prefab creation thing so sorry for the noob question here but...

 

what do I need to do to export a prefab from in game and into the editor for saving?

 

Thanks!

-Bear

 

You can either use hals dll or my api mod for exporting atm (might be oithers?)

 

hals you can run on local game, my mod has to be on dedi server

 

- - - Updated - - -

 

explain to me how the sleeper volume system works.

 

The main thing with them, is they are a list (or array) of settings

 

To use the 5 floor apartment as an example:

 

<property name="SleeperVolumeStart" value="0, 0, 4#0, 6, 4#0, 10, 4#0, 14, 4#0, 18, 4#35, 18, 4" />
<property name="SleeperVolumeSize" value="45, 6, 33#45, 4, 33#45, 4, 33#45, 4, 33#45, 11, 33#10, 11, 8" />

 

This is a # separated list of vectors. Start is the co-ords within the prefab from 0,0 being bottom sw corner, Size mesasures the total volume

so the first volume is from 0,0,4 to 45,6,37 (0,0,4 + 45,6,33)

 

<property name="SleeperVolumeGroup" value="S_Default_Med,S_Default_Med,S_Default_Med,S_Default_Med,S_Default_Med,S_LootRoom_S" />

 

Group is a csv of the entitygroup to use for that volume

 

<property name="SleeperVolumeGameStageAdjust" value=",,,,,medium" />

 

A csv of gamestage modifiers to apply (easy: +150, medium: +300, hard: +500) - (see gamestages.xml)

 

<property name="SleeperIsLootVolume" value="False,False,False,False,False,True" />

 

Csv of ? - not quite sure on this one. Reading the code it kinda looks like it activates sleeper spawn points or something, but I'm probably reading that wrong as the other ones def work.

Edited by StompyNZ (see edit history)

Share this post


Link to post
Share on other sites
You can either use hals dll or my api mod for exporting atm (might be oithers?)

 

hals you can run on local game, my mod has to be on dedi server

 

 

Thanks Stompy, I appreciate the reply!

 

-Bear

Share this post


Link to post
Share on other sites

so the first volume is from 0,0,4 to 45,6,37 (0,0,4 + 45,6,33)

 

Thanks Stompy. I wasn't quite sure about the meaning of the SleeperVolumeSize variable.

 

@CombatLoaded

what do I need to do to export a prefab from in game and into the editor for saving?

 

You don't need the editor to save a prefab. That's already done when you export the prefab.

Edited by Pille (see edit history)

Share this post


Link to post
Share on other sites

Pille. So I was thinking. When viewing the blocks in the editor, it would be cool if the sleeper blocks would include that little icon you use for your editor. Yes, sure, you would need to tag those blocks with "isZombie" or something every time they added one, but it would sure help "see" where the blocks are with a quick glance.

 

Also, once you get a handle on volumes, clicking on one and seeing a visual representation of the volume space would also be cool.

Share this post


Link to post
Share on other sites
Pille. So I was thinking. When viewing the blocks in the editor, it would be cool if the sleeper blocks would include that little icon you use for your editor. Yes, sure, you would need to tag those blocks with "isZombie" or something every time they added one, but it would sure help "see" where the blocks are with a quick glance.

 

Also, once you get a handle on volumes, clicking on one and seeing a visual representation of the volume space would also be cool.

 

I've spent quite some time the past couple weeks looking at how I can repair/continue my hub and get a decent first round of sleepers in there too, it's a gigantic amount of work. I've now found a point where I'm working at a decent pace, starting the process a section at a time (considering the content of some of them) and as I seem to be struggling in a similar area to you (more specifically adding 'extras' the easy way after the first lot are set in) in that there's no quick easy way to see em in game.

 

So I'm using hal's empty world/DLL, loading one up, dm & editor mode enabled. Second screen has pilles editor. The reason I use both is fixing jobs, like rows of borked poles or big areas of dodgy blocks can be done in the editor and saved, then instantly loaded up in the empty world. If a particular job needs done by hand, or I need a reference for a rotation then I whack em down and 'prefab save' then I can load this back up into pilles editor. Im working faster now I think than I could ever have before.

 

Working this way has a few snags which I hinted at earlier, using 'prefab save' ingame or maybe it's saving via the editor cleans out the prefabs XML so I''ve started writing my sleeper groups in my backup then dropping them into the game folder at the end to test. Also once sleepers are saved into the .tts, when the prefab is loaded back up ingame they are invisible and if the prefab is saved via 'prefab save' the sleeper blocks will be removed, which is kinda related to your issue.

 

My counter atm is when I consider a section 'finished' and ready for sleeper groups, I place my sleepers in game a group at a time in a single round as the 'final job' and write the xml as I go. You could on a small build just place em all in a single shot quite fast and 'prefab save' em in as it's easy enough with the editor woring out the coords needed. I'm keeping notes per section of the order I add groups to the xml, but thats for easy tracking as I expect the hub in total to contain at least 500 or so spawn areas but the gamestages XML seems quite flexable as the master controller for really turning things up or down once the groups are set into the prefabs.

 

Once my sleepers are added tho they are blocked out of using this easy method of placing them in, I dunno if there's a tweak could be made to the DLL as I'm sure in the first build it was released in you could re-load a prefab with the sleeper blocks visible by default. It's far from the end of the world tho, pille has done an awesome job the past couple weeks refining the editor and as rotations are much less an issue with sleepers making minor adjustments or additions can be done on the fly.

Share this post


Link to post
Share on other sites

@Slaan: Wow, I'm not quite that far into fixing Guppyville, but you've given me some good ideas. :)

 

@Pille: We could use a "Save Prefab", "Save XML", and "Save Both" option Pille.

 

...also a history of recently opened files. :)

 

@All: I'm uploading the first of my "Tutorial" videos with this editor. I'll be adding more as I review my teamviewer session with Pille and remember more stuff. I got uh, distracted this weekend. Project Coaster is amazing. :)

 

Anyway, whe it's finished uploading and processing, the video is here:

 

[video=youtube;DU0-yK6yc8Q]

  • Like 1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...