Bay 12 Games Forum

Dwarf Fortress => DF Modding => Utilities and 3rd Party Applications => Topic started by: mifki on March 19, 2017, 03:58:55 pm

Title: TWBT Next
Post by: mifki on March 19, 2017, 03:58:55 pm
I suddenly found an easy and reliable way to implement new rendering features I was thinking about for a long time. A separate thread to attract attention of tileset authors because the new features require changes to tilesets.

(http://mifki.com/assets/uploads/Screen-Shot-2017-03-20-at-12.25.29-AM.png)

Features

1. Buildings and items are now rendered separately from the floor - you can notice that coffins, chairs, slabs and so on have different colours but their backgrounds stay the same, and are actual floor tiles - rough, smooth, engraved. No stockpiles on this screenshots, but you'd see stockpile tiles behind items as well.

2. Look at the beds. The bed frames have different colours depending on their material, but pillows and sheets stay the same, i.e. not all tile pixels are affected by the foreground colour.

3. Oblique view mode I showed here http://www.bay12forums.com/smf/index.php?topic=138754.msg7390751#msg7390751 It's not available at the moment, I'll update the post later.

Tileset changes

1. Existing tilesets will continue to work as usual.

2. To support these new features, tilesets need to have three "layers":

(http://mifki.com/assets/uploads/Screen-Shot-2017-03-20-at-9.18.59-AM.png)

First is used to render background colours and normally should just be white for non-empty tile pixels. This is supplied as e.g. Spacefox-bg.png
Second is the main tile image which will be coloured using foreground tile colour, can now have fully transparent pixels where floor should be visible. This is supplied as usual Spacefox.png
Third is just the pixels that won't change colour. This is supplied as Spacefox-top.png
If -bg and -top files are not available, the corresponding features will be disabled and the tileset will work as before.

Notes

1. Binaries are available from build.mifki.com (http://build.mifki.com). When installing, copy white1px.png and transparent1px.png to data/art folder. An example tileset based on Spacefox is included.

2. This works the same way for overrides, just supply additional -bg and -top images for each tileset used by overrides. However due to 3 times more tiles now being used and restrictions on the largest texture size, tileset authors using a lot of overrides and/or very big tile sizes need to be careful not to waste any space in tileset images, i.e. having three images with just half of the tiles actually used is bad because all tiles will still be loaded.

3. If you can't see the floor though some of the buildings/items, it's because I forgot to include them, there are quite a few of such (that is, in the code, the example tileset has just a few tiles modified to demo the new features).
Title: Re: TWBT Next
Post by: Vherid on March 19, 2017, 06:48:49 pm
Increasingly impressive work
Title: Re: TWBT Next
Post by: Rydel on March 20, 2017, 08:01:24 am
Well, time to spend a week reworking and reorganizing Rally Ho!.
I've really been wanting these features, so I'll need to add them right away, but I'll probably have to combine so override image sets.

EDIT: Am I correct in assuming that this only applies to tilesets and not creature graphics?
Title: Re: TWBT Next
Post by: mifki on March 20, 2017, 03:16:45 pm
EDIT: Am I correct in assuming that this only applies to tilesets and not creature graphics?

Yep. I tried to find a way to support creatures too last night, but no luck so far.
Title: Re: TWBT Next
Post by: Rydel on March 20, 2017, 05:38:37 pm
white1px.png and transparent1px.png don't seem to be included (though I think I can guess their contents)
Also, would it be possible for the zip to include the folder structure?  It would make installation much simpler.
Title: Re: TWBT Next
Post by: mifki on March 20, 2017, 05:51:15 pm
white1px.png and transparent1px.png don't seem to be included (though I think I can guess their contents)

Oh, I forgot to push them to github again. http://mifki.com/a/t/white1px.png http://mifki.com/a/t/transparent1px.png

Also, would it be possible for the zip to include the folder structure?  It would make installation much simpler.

One of the reasons is that on macOS, when you copy folder structure to a location where same folders already exist, they will be overwritten, not merged. Better to copy everything manually than give users a chance to lose their saves.
Title: Re: TWBT Next
Post by: Amostubal on March 22, 2017, 09:33:30 am
ptw
I know a tileset I would like to see modded to utilize this.... I'll have to go put a bug in someones's ear...
Title: Re: TWBT Next
Post by: Rydel on March 22, 2017, 06:53:12 pm
I seem to be encountering an issue with the new version in Windows 8.1.  When I embark on a site with TWBT on, the game crashes when leaving the "Strike the Earth" screen.  It works fine if I change the print mode to standard and has the same issue with just the curses font instead of my tileset.
Title: Re: TWBT Next
Post by: Amostubal on March 22, 2017, 07:36:35 pm
so this is basically the latest version of TWBT with an option to add in XX-bg.png and XX-top.png of your image file? So if the extra files aren't available it would just operate as the normal version?  I see its 43.05 now i finally downloaded it and opened it lol...

oh and just so you know your site throws certification errors on chrome:

This server could not prove that it is build.mifki.com; its security certificate is not trusted by your computer's operating system. This may be caused by a misconfiguration or an attacker intercepting your connection. Learn more.

lol, I trust you, but I just wanted you to know what it said.
Title: Re: TWBT Next
Post by: mifki on March 23, 2017, 02:33:41 am
I seem to be encountering an issue with the new version in Windows 8.1.  When I embark on a site with TWBT on, the game crashes when leaving the "Strike the Earth" screen.  It works fine if I change the print mode to standard and has the same issue with just the curses font instead of my tileset.

Hm, I tested on Windows now and doesn't crash for me. Does the normal TWBT 5.77 work fine if you just copy it instead?

Did anyone else try the new version on Windows?

so this is basically the latest version of TWBT with an option to add in XX-bg.png and XX-top.png of your image file? So if the extra files aren't available it would just operate as the normal version?

It renders things a bit different way. But for end users yes the result is the same if no additional images present.
Title: Re: TWBT Next
Post by: Rydel on March 23, 2017, 06:09:53 pm
TWBT 5.78 works.  It's just TWBT Next
Title: Re: TWBT Next
Post by: mifki on March 25, 2017, 05:01:19 am
TWBT 5.78 works.  It's just TWBT Next

Try version 6.11 please.
Title: Re: TWBT Next
Post by: Rydel on March 25, 2017, 07:22:13 am
It's working in 6.11.  Thank you.

EDIT: It looks like thread, bags, and splints aren't showing the background.
Title: Re: TWBT Next
Post by: SalmonGod on April 07, 2017, 12:52:59 am
PTW
Title: Re: TWBT Next
Post by: onarum on April 12, 2017, 12:08:48 am
Forgive my ignorance, but in which folder exactly am I supposed to drop the lua script?
Title: Re: TWBT Next
Post by: mifki on April 12, 2017, 02:45:07 am
Forgive my ignorance, but in which folder exactly am I supposed to drop the lua script?

The Lua script is not required. I can't find a post where I explain what it does right now.
Title: Re: TWBT Next
Post by: mifki on April 19, 2017, 11:01:30 pm
Since no one is complaining, this will now be merged into the main code (which was the plan anyway). I will also probably update several tilesets myself to use the new features as an example.
Title: Re: TWBT Next
Post by: waterphage13 on April 28, 2017, 03:58:13 pm
Subcolors don't work.
TWBTnext:
(https://pp.userapi.com/c837529/v837529146/34685/Q8xayeA04sA.jpg)
Normal:
(https://pp.userapi.com/c837529/v837529146/346a4/jyhx4KFlRfw.jpg)
Title: Re: TWBT Next
Post by: mifki on April 29, 2017, 05:10:12 am
Subcolors? What?
Title: Re: TWBT Next
Post by: Obsidian Soul on April 30, 2017, 03:18:30 am
I'm using LNP to quickly update files to test for the 32x tileset I'm continuing, and this plugin does not work at all with the last official release (2016) of LNP. It won't load with the dfhack version there.

But using the beta release of LNP and dfhack (43.05 64bit beta (http://dffd.bay12games.com/file.php?id=12743)) and manually installing the file here seems to work.

Did a quick test with making -bg and -top files and it worked beautifully! :D Haven't yet edited the raws of the colors, but it is very clearly showing the underlying floors. These are various rough gems (zircons, spessartines, spinels) and mined rock (phyllite) in a stockpile, as well as microcline (light blue) and gabbro (black) in a rough gabbro floor.

(http://i.imgur.com/gvfjiWI.png)

Questions:

1. Is this restricted only to tiles that can be overridden, or can the main tileset have a -bg and -top file too?
2. Is there a way to extend this functionality to creatures and units?
3. I've also encountered this, where mined rock was in the middle of a stairwell. The background it acquires doesn't seem to be the stairs, but the pointer tileset (a compass rose in default Meph, shown beside it for comparison). Is this one of the backgrounds you meant that haven't been added yet? Or is it just a hardcoded issue?

(http://i.imgur.com/x1R9khU.png)

Anyway... this is exciting! :D

EDIT:
Ran into more serious issues. I think the background colors being stripped from other tilesheets is what waterphage13 meant by subcolors. All the tiles seem to lose their background colors. This issue persists even if you remove the -bg and -top files.

(http://i.imgur.com/J3ET9Vd.jpg)
Title: Re: TWBT Next
Post by: Rydel on April 30, 2017, 07:07:46 am
That sounds like the official release isn't using the latest version of DFHack, but the beta is.

That's a nice looking tileset.

1. The main tileset can be given top an bg files, though certain tiles display floor below them.  Obviously, this will include tiles that are themselves floor tiles, but it also includes some other, less obvious tiles, such as stairs and outdoor rocks.
2. TWBT doesn't affect creatures, but this be a nice feature to see in the future.
3. Don't know the answer to this one.

I hadn't noticed the broken transparency, but I don't think I engraved any walls in my test, which is where the most obvious tileset magic is used.
Title: Re: TWBT Next
Post by: Obsidian Soul on April 30, 2017, 07:28:11 am
That sounds like the official release isn't using the latest version of DFHack, but the beta is.

That's a nice looking tileset.

1. The main tileset can be given top an bg files, though certain tiles display floor below them.  Obviously, this will include tiles that are themselves floor tiles, but it also includes some other, less obvious tiles, such as stairs and outdoor rocks.
2. TWBT doesn't affect creatures, but this be a nice feature to see in the future.
3. Don't know the answer to this one.

I hadn't noticed the broken transparency, but I don't think I engraved any walls in my test, which is where the most obvious tileset magic is used.

Awesome. :)

Yeah. I only noticed the bg color error on like my fourth test when I took a quick look outside at my plants.

Unfortunately it's game-breaking for me, as my bg color is used heavily for tileset magic (fruits, material, etc.), while the fg color is used exclusively for coherence (match surrounding tiles, plants on grass, etc.).

It's not a problem for items, since the background would be the tile beneath them, but plants don't have an underlying tile, so the default bg color is black (which is bad for tilesets like mine). I could set the grass surrounding them to be fixed in color (e.g. permanently green), but it would ruin snow-covered/dry/wet/dead effects.
Title: Re: TWBT Next
Post by: mifki on April 30, 2017, 07:58:43 am
Unfortunately it's game-breaking for me, as my bg color is used heavily for tileset magic (fruits, material, etc.), while the fg color is used exclusively for coherence (match surrounding tiles, plants on grass, etc.).

Can you share tileset files for me to test with?
As for the stairs/cursor issue, yeah, "background" tiles that are themselves overridden need special handling, will need to fix that.
Title: Re: TWBT Next
Post by: Obsidian Soul on April 30, 2017, 04:07:05 pm
Unfortunately it's game-breaking for me, as my bg color is used heavily for tileset magic (fruits, material, etc.), while the fg color is used exclusively for coherence (match surrounding tiles, plants on grass, etc.).

Can you share tileset files for me to test with?
As for the stairs/cursor issue, yeah, "background" tiles that are themselves overridden need special handling, will need to fix that.

I've upped the playable WIP version (for LNP beta/LNP) in dffd here: http://dffd.bay12games.com/file.php?id=12876 (http://dffd.bay12games.com/file.php?id=12876)

Note that it is still very early WIP, so most of it is still Meph's tileset which I'm using as the template. I'm mostly done with the plants (base graphics and modified plant raws). I haven't yet gotten around to the picked tiles, so they'll just be blank grass for now, but there's enough there to accurately show outside/cavern biomes of the finished set.

The items tilesheet already has a few items that are edited for TWBTNext, with corresponding -bg and -top files. So you can use those as quick test tiles. They are arrows, bolts, darts, plate armor, chainmail, leather armor, high boots, low boots, spider web, barrel (stockpile), a mason workshop tile, mined rock, large gem, cut gem, and rough gem.

I've also included my old tile master file for making new masks, as well.
Title: Re: TWBT Next
Post by: mifki on April 30, 2017, 05:46:27 pm
Ok I see the problem. Backgrounds can be fixed by explicitly providing fully white -bg images until I make a new version, there's a bug with loading the default white1px.png if no -bg file is present.
Title: Re: TWBT Next
Post by: Obsidian Soul on April 30, 2017, 06:02:47 pm
Ok I see the problem. Backgrounds can be fixed by explicitly providing fully white -bg images until I make a new version, there's a bug with loading the default white1px.png if no -bg file is present.

Awesome! Cheers.  :D
Title: Re: TWBT Next
Post by: Obsidian Soul on April 30, 2017, 06:56:25 pm
It works. Added -bg files for all the tilesheets (including the main tilesheet) and the bg colors are back for the plants. I'm assuming now that the "middle" layer is affected by both fg and bg colors as normal, instead of only the fg color as mentioned in the description in the first post.

Still have some flickering (redraw?) issues, where some tiles will show a black background until I move the screen or zoom in/out. But I understand it's far from finished. This is good enough to work with. :)

P.S. using the beta1 version since LNP has no release for beta2 64bit win yet.

(http://i.imgur.com/rXP8KCh.png)
Title: Re: TWBT Next
Post by: mifki on April 30, 2017, 07:00:14 pm
I didn't notice it during my quick testing, it shouldn't be like that, i.e. it's not in development, so I'll check again. Can you see if there's any difference if you execute "twbt redraw_all 1" cmd?
Title: Re: TWBT Next
Post by: Obsidian Soul on April 30, 2017, 07:16:26 pm
I didn't notice it during my quick testing, it shouldn't be like that, i.e. it's not in development, so I'll check again. Can you see if there's any difference if you execute "twbt redraw_all 1" cmd?

Nope. The tiles with the black backgrounds remain black.

However, it remains VERY specific to where the map focus actually is (i.e. the area shown in the window).

e.g. If you position over a certain area, certain specific tiles will have a black background. Move the map focus to the left, and it disappears (though other new tiles will show new errors). However move map focus back to the right, and the same errors will show up as the first time.
(http://i.imgur.com/lnhhwrF.png)

Zooming in/out also crashes the game at times.

As mentioned, I'm using the beta1 version since LNP has no release for beta2 64bit win yet.
Title: Re: TWBT Next
Post by: mifki on April 30, 2017, 07:29:54 pm
Oh I had to use colour picker as I couldn't see any difference. Why do people like such dark colours... Anyway, I'll look into this later today, hopefully.
Title: Re: TWBT Next
Post by: Obsidian Soul on April 30, 2017, 07:40:44 pm
LOL. sorry, it's WIP, I haven't adjusted yet. The dark bg colors is primarily to mask the backgrounds in tilesets like mine, which is why this plugin would be awesome for finally removing that requirement. Here's one with a lighter stockpile tile:

(http://i.imgur.com/Pp6FQ8Y.png)
Title: Re: TWBT Next
Post by: Obsidian Soul on May 01, 2017, 12:38:15 am
It seems to only be affecting certain tiles, so I have a suspicion it's because the -bg mask isn't 100% opaque white vs. transparent (i.e. it has aliasing). I'm gonna a bit of experimentation, will get back with results.

EDIT: Nah, wasn't it.
Title: Re: TWBT Next
Post by: Rose on May 01, 2017, 01:21:10 am
I'm curious, does twbt currently allow more than the 16 default colors for materials? Either as overrides or by using the state colors?
Title: Re: TWBT Next
Post by: mifki on May 01, 2017, 06:24:03 am
I'm curious, does twbt currently allow more than the 16 default colors for materials? Either as overrides or by using the state colors?

Yes. If you set material basic/build/tile colour to value >= 100, it will use colour from df.global.world.raws.language.colors[value-100] instead. No one is using this feature as far as I know so it didn't get developed further.
Title: Re: TWBT Next
Post by: Rose on May 01, 2017, 10:07:16 am
In that case, I'm going to make a script to convert all the colors I have to language colors.
Title: Re: TWBT Next
Post by: DragonDePlatino on May 02, 2017, 09:38:45 pm
This is really impressive! With the addition of transparent buildings I think you've solved the last big issue facing Dwarf Fortress graphics. PTW
Title: Re: TWBT Next
Post by: Rose on May 04, 2017, 02:40:40 am
I'm curious, does twbt currently allow more than the 16 default colors for materials? Either as overrides or by using the state colors?

Yes. If you set material basic/build/tile colour to value >= 100, it will use colour from df.global.world.raws.language.colors[value-100] instead. No one is using this feature as far as I know so it didn't get developed further.

This is actually rather unsafe, because it depends on the color definitions never being modified, which is not guaranteed. Simply adding a single extra language color would mean that everything is changed.
Title: Re: TWBT Next
Post by: PatrikLundell on May 04, 2017, 04:02:53 am
I'm curious, does twbt currently allow more than the 16 default colors for materials? Either as overrides or by using the state colors?

Yes. If you set material basic/build/tile colour to value >= 100, it will use colour from df.global.world.raws.language.colors[value-100] instead. No one is using this feature as far as I know so it didn't get developed further.

This is actually rather unsafe, because it depends on the color definitions never being modified, which is not guaranteed. Simply adding a single extra language color would mean that everything is changed.
Rather than complaining that the dog speaks poorly, we should be amazed that it speaks at all.

The caution is valid, of course.
If I understand it correctly, tile set installations tend to do a lot of things to files, and locking down descriptor_color_standard.txt would be rather reasonable when the tile set depends on it (in particular if it also adjusts color values to match the tile set theme).
If we're not talking about a tile set, but rather a tool, I'd consider doing the translation on tool startup/connection to DF/loading of a save, or just a straight comparison and refusal to work (with an appropriate error message, of course) on a mismatch.

I have to say this TWBT Next thing looks rather impressive, both additional colors and more power for tiles. The concern I have is if it has a significant FPS effect (I've made some DFHack scripts that became rather sluggish even though the only thing happening was rendering).
Title: Re: TWBT Next
Post by: mifki on May 04, 2017, 04:43:39 am
I'm curious, does twbt currently allow more than the 16 default colors for materials? Either as overrides or by using the state colors?

Yes. If you set material basic/build/tile colour to value >= 100, it will use colour from df.global.world.raws.language.colors[value-100] instead. No one is using this feature as far as I know so it didn't get developed further.

This is actually rather unsafe, because it depends on the color definitions never being modified, which is not guaranteed. Simply adding a single extra language color would mean that everything is changed.

It's supposed to be used with a script setting these values somehow. Of course no-one is going to use "100+" values in raws. In fact, there's a script included in twbt package that sets basic/build/tile colours of materials equal to their real state_color values.
Title: Re: TWBT Next
Post by: PeridexisErrant on May 15, 2017, 07:52:33 am
Came here from the mainline release note - PTW, so I can switch over the Starter Pack when this is stable.  It looks fantastic!

Of course no-one is going to use "100+" values in raws.
You're an optimist  :P
Title: Re: TWBT Next
Post by: Amostubal on May 15, 2017, 07:27:26 pm
100+ values... I would...lol
Title: Re: TWBT Next
Post by: Amostubal on May 19, 2017, 06:59:38 am
Since no one is complaining, this will now be merged into the main code (which was the plan anyway). I will also probably update several tilesets myself to use the new features as an example.

So mifki is twbt next in the current version of twbt or is still a separate package? Is it something that will have to be switched on?  I really enjoy this, and I'm watching a couple of artists who are working on the tileset...  just making sure I don't have to do a complete rewrite of my pack to get it to work, lol.

cheers on your work, I really don't enjoy playing DF anymore without you.
Title: Re: TWBT Next
Post by: mifki on May 19, 2017, 07:43:02 pm
Since no one is complaining, this will now be merged into the main code (which was the plan anyway). I will also probably update several tilesets myself to use the new features as an example.

So mifki is twbt next in the current version of twbt or is still a separate package? Is it something that will have to be switched on?  I really enjoy this, and I'm watching a couple of artists who are working on the tileset...  just making sure I don't have to do a complete rewrite of my pack to get it to work, lol.

cheers on your work, I really don't enjoy playing DF anymore without you.

Currently it's separate but I'll merge it into the main branch once I have time to fix last couple things. There are no new options or anything, it should work just like the old twbt with existing tilesets that don't have -bg & -top files, and will enable the new features if these files are supplied.
Title: Re: TWBT Next
Post by: Amostubal on May 20, 2017, 08:46:45 am
Since no one is complaining, this will now be merged into the main code (which was the plan anyway). I will also probably update several tilesets myself to use the new features as an example.

So mifki is twbt next in the current version of twbt or is still a separate package? Is it something that will have to be switched on?  I really enjoy this, and I'm watching a couple of artists who are working on the tileset...  just making sure I don't have to do a complete rewrite of my pack to get it to work, lol.

cheers on your work, I really don't enjoy playing DF anymore without you.

Currently it's separate but I'll merge it into the main branch once I have time to fix last couple things. There are no new options or anything, it should work just like the old twbt with existing tilesets that don't have -bg & -top files, and will enable the new features if these files are supplied.

awesome, I can't wait to hear it's ready.  I've tried it some and it seems great, but I don't want to push it into mainstream MW until you say its ready.
Title: Re: TWBT Next
Post by: daagar on May 27, 2017, 11:54:05 am
This is phenomenal. The 'black box' look due to replaced backgrounds was a definite eyesore, and one I assumed we were simply stuck with. I really can't wait to see tilesets support this, especially with the current 'cream of the crop' tilesets under active development right now.
Title: Re: TWBT Next
Post by: Rose on May 27, 2017, 01:07:43 pm
Suggestion, if you manage to implement tall tiles, so to speak:

Have lower levels be offset on the Y axis.
Title: Re: TWBT Next
Post by: mifki on May 28, 2017, 04:52:04 am
Have lower levels be offset on the Y axis.

They are, of course.
Title: Re: TWBT Next
Post by: Moonshine Fox on June 09, 2017, 03:59:09 am
Mifki, I keep getting certificate errors both accessing your site and downloading via WGet. You have any idea why?
Title: Re: TWBT Next
Post by: Moonshine Fox on June 09, 2017, 08:49:31 am
In addition I seem to be getting a completely black screen rather often. For instance, if I visit the Z (Status) screen and switch back to map view, it'll be completely black and won't come back unless I do something to update the window size (such as restore and maximize the window again).

Running on Archlinux x64 with Nvidia prop. drivers 381.22-2.
Title: Re: TWBT Next
Post by: mifki on June 11, 2017, 04:48:06 pm
Mifki, I keep getting certificate errors both accessing your site and downloading via WGet. You have any idea why?

Because when I created that server there was no Letsencrypt, and then I never bothered.

In addition I seem to be getting a completely black screen rather often. For instance, if I visit the Z (Status) screen and switch back to map view, it'll be completely black and won't come back unless I do something to update the window size (such as restore and maximize the window again).

Running on Archlinux x64 with Nvidia prop. drivers 381.22-2.

Yeah, I know, try the previous build https://build.mifki.com/download/937/artifacts/twbt-next-6.15-linux.zip There were some changes in the latest one that are not fully tested.
Title: Re: TWBT Next
Post by: Moonshine Fox on June 15, 2017, 07:04:28 am
Mifki, I keep getting certificate errors both accessing your site and downloading via WGet. You have any idea why?

Because when I created that server there was no Letsencrypt, and then I never bothered.

In addition I seem to be getting a completely black screen rather often. For instance, if I visit the Z (Status) screen and switch back to map view, it'll be completely black and won't come back unless I do something to update the window size (such as restore and maximize the window again).

Running on Archlinux x64 with Nvidia prop. drivers 381.22-2.

Yeah, I know, try the previous build https://build.mifki.com/download/937/artifacts/twbt-next-6.15-linux.zip There were some changes in the latest one that are not fully tested.

Gotcha! I'll check that. Thanks!
Title: Re: TWBT Next
Post by: mifki on June 15, 2017, 04:16:34 pm
Mifki, I keep getting certificate errors both accessing your site and downloading via WGet. You have any idea why?

Because when I created that server there was no Letsencrypt, and then I never bothered.

In addition I seem to be getting a completely black screen rather often. For instance, if I visit the Z (Status) screen and switch back to map view, it'll be completely black and won't come back unless I do something to update the window size (such as restore and maximize the window again).

Running on Archlinux x64 with Nvidia prop. drivers 381.22-2.

Yeah, I know, try the previous build https://build.mifki.com/download/937/artifacts/twbt-next-6.15-linux.zip There were some changes in the latest one that are not fully tested.

Gotcha! I'll check that. Thanks!

Well, it's been fixed since then, I hope, so now try the latest one :)
Title: Re: TWBT Next
Post by: Moonshine Fox on July 02, 2017, 03:56:16 am
Anyone have any idea as to why this keeps happening?

http://i.imgur.com/JEdzVMr.png (http://i.imgur.com/JEdzVMr.png)
Title: Re: TWBT Next
Post by: Clément on July 12, 2017, 03:08:49 am
Hi, I've just discovered this version of TWBT and I was testing a quick conversion of Mayday's tileset.

In normal mode, planned buildings (table and chair) are replaced with green X (https://tof.cx/images/2017/07/12/4c5e09016423abf47a6c7dc267ab57ac.png), but it is drawn correctly when I switch to look mode (https://tof.cx/images/2017/07/12/f329fbace51ad86c7090e77b5b98988b.png). Any idea why?

By the way, if you look at the booze stockpile just below, there are tiles with goblets that have a black background. I think it is because you only draw the two top objects (two goblets), it may look better if the top and bottom objects were drawn instead (or all of them, but I guess it is bad for performance).
Title: Re: TWBT Next
Post by: mifki on July 12, 2017, 05:25:42 am
In normal mode, planned buildings (table and chair) are replaced with green X (https://tof.cx/images/2017/07/12/4c5e09016423abf47a6c7dc267ab57ac.png), but it is drawn correctly when I switch to look mode (https://tof.cx/images/2017/07/12/f329fbace51ad86c7090e77b5b98988b.png). Any idea why?

Isn't this what "resume" plugin does? Anyway, I don't think TWBT can do it.

By the way, if you look at the booze stockpile just below, there are tiles with goblets that have a black background. I think it is because you only draw the two top objects (two goblets), it may look better if the top and bottom objects were drawn instead (or all of them, but I guess it is bad for performance).

Hm, I thought I had some code to avoid this, I'll take a look. Thanks for letting me know, that's basically why I still haven't made Next the main version, I want to give people time to discover what special cases are causing troubles with the new multilayer rendering.
Title: Re: TWBT Next
Post by: Clément on July 12, 2017, 06:22:54 am
Isn't this what "resume" plugin does? Anyway, I don't think TWBT can do it.

I think it is the "buildingplan" plugin. It allows to build suspended building without having the furniture ready and then automatically resume them when the furniture is available. It displayed correctly as inverted tiles with the previous version of TWBT. The bug does not appear with a normal suspended building, it may be related to the "unknown" material.

I forgot to get out of look mode after suspending the normal building. You were right, it must be the resume plugin. It must be a new feature from when I updated dfhack, I did not have that before. Solved with "resume hide".
Title: Re: TWBT Next
Post by: Clément on July 12, 2017, 08:48:46 am
My black background problem may be more complex than I first described.

(https://tof.cx/images/2017/07/12/e68d62af6fc3ebe0091c3c1052e23eca.md.png) (https://tof.cx/image/pOY3X)

In both armor and weapon stockpile, there is only one item per tile (item + stockpile + ground, as seen in the look window). But armors have transparent background, weapons don't. The weapons in stacks near the top left corner of the weapon stockpile have transparency (you can see two items), so I think my tilesets are done correctly (I can upload them, if someone wants to check).

There is a similar problem with the block stockpile: some of the blocks with black background are alone on their tile. The block over stockpile background in the top left corner is actually stacked with several other blocks and a bin.

I think my bags are also victim of this.

There is also the same problem as Obsidian Soul, where a few tiles may have a black background depending on the position of the view, but it is more rare (the top left and bottom left blocks in the stockpile may have stockpile or black background depending on the position, other tiles don't seem to change).
Title: Re: TWBT Next
Post by: mifki on July 12, 2017, 05:25:38 pm
Yeah I mentioned in the first pos I might have forgotten to handle some item types, that's the case with weapons at least. I'll fix this and check other problems on you screenshots as soon as I can. If you could upload your tileset that would help as it likely has more properly done tiles than my test tilesets, so I'll be able to spot more issues.
Title: Re: TWBT Next
Post by: lethosor on July 12, 2017, 08:27:53 pm
Isn't this what "resume" plugin does? Anyway, I don't think TWBT can do it.

I think it is the "buildingplan" plugin. It allows to build suspended building without having the furniture ready and then automatically resume them when the furniture is available. It displayed correctly as inverted tiles with the previous version of TWBT. The bug does not appear with a normal suspended building, it may be related to the "unknown" material.

I forgot to get out of look mode after suspending the normal building. You were right, it must be the resume plugin. It must be a new feature from when I updated dfhack, I did not have that before. Solved with "resume hide".
Try replacing your resume plugin with the one included in TWBT.
More: http://www.bay12forums.com/smf/index.php?topic=126076.msg7492491#msg7492491
Title: Re: TWBT Next
Post by: mifki on July 12, 2017, 09:07:39 pm
Try replacing your resume plugin with the one included in TWBT.

No it's not this, he was talking about the normal plugin behaviour he wasn't familiar with, as I understand.
Title: Re: TWBT Next
Post by: lethosor on July 12, 2017, 09:37:01 pm
Sorry, I must have read that wrong.
Title: Re: TWBT Next
Post by: Clément on July 13, 2017, 03:36:47 am
Forget about resume. I don't know why I did not see it before but it is fixed now.

Here (https://framadrop.org/r/Xeptc2hCAY#HXxvACJBloqbRe3YrEAU3yvl8dy1BzJw9Ziv0mC6I4I=) is an archive with modified mayday and meph's items tilesets. I included the xcf (gimp image files) if you want to tweak them (I simply paint the masks and export the layers).

In case you don't have the overrides for the items, here they are:
Spoiler (click to show/hide)
Title: Re: TWBT Next
Post by: mifki on July 20, 2017, 07:05:37 am
New build is available (for 0.43.05-r2) which hopefully fixes most of the issues.
Title: Re: TWBT Next
Post by: Clément on July 20, 2017, 08:09:04 am
Thanks for the new version.

My remarks after a quick test:

I don't know how this works, but would it be possible to draw more than two tiles (as a configurable setting maybe)? I liked how drawing items over one another made some tiles feel cluttered (and they actually are). Ideally, I'd like to have: ground/construction + stockpile/building + a few items, but I don't know if it is possible or easy.
Title: Re: TWBT Next
Post by: lethosor on July 20, 2017, 08:53:47 am
  • resume and automaterial plugins are not present in the new archive. Are they no longer necessary?

They shouldn't be: https://github.com/mifki/df-twbt/pull/59
Title: Re: TWBT Next
Post by: mifki on July 20, 2017, 04:29:19 pm
  • Transparency for workshop tiles used to work, but does not any more (black background instead of ground tile).

Yeah was experimenting with this and disabled it. I was going to maybe make it configurable as I'm not completely sure transparency for workshops is required. The problem is that tiles used in workshops will most likely have transparency as they're used in other places, but this makes it difficult to notice workshops on some backgrounds - unless tileset provides overrides for all workshops. But probably I shouldn't have disabled it in the build, right.

  • I forgot to tell it before: the trade depot is not drawn below the items it contains (in addition to the old issue of overrides not working for these items).

I'll check again, I looked at depots briefly and didn't notice.

I don't know how this works, but would it be possible to draw more than two tiles (as a configurable setting maybe)? I liked how drawing items over one another made some tiles feel cluttered (and they actually are). Ideally, I'd like to have: ground/construction + stockpile/building + a few items, but I don't know if it is possible or easy.

Well, as it's implemented currently, it's two layers only. However I'll probably try other ways later. Game draws (i.e. calls the draw function for) all the items anyway, and OpenGL performance isn't a problem nowadays, so we should be able to draw more stuff.
Title: Re: TWBT Next
Post by: waterphage13 on August 21, 2017, 05:44:43 pm
How progress with background colors?
Title: Re: TWBT Next
Post by: mifki on August 21, 2017, 05:55:55 pm
How progress with background colors?

There were some fixes, have you tried the latest version?
Title: Re: TWBT Next
Post by: vvAve on August 22, 2017, 02:47:20 am
Any tilesets to test new features?
Title: Re: TWBT Next
Post by: mifki on September 20, 2017, 09:05:51 am
All the Next features have now been merged into the main branch (version 6.21).