TilemapEd, Tilemap editor for the X16

Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

I just uploaded TilemapEd version 1.8.99 to GitHub, which has an initial version of Text Overlays.

The Overlays for the TileMap editor are "Tile Values" and "Collision Values" with "Tile Values" being "Tile Index", Flip and if available "Palette Offset".
When a CollisionMap is present this Overlay is just the "Collision Value".

For the TileSet Editor the Overlay is "Tile Index".

The Overlays can be toggled with <TAB> or enabled in "View->Overlay".

One thing that was completely impossible was finding a text color that works in all cases. I still haven't quite figured out this problem, but right now there's a simple setting in "File->Settings->Overlay Text Color" where the color can be set to White or Black.
The value still isn't written to the settings file since I'm still not sure what the best solution is and also users will probably end up changing this color fairly often, when using the feature.

When the Tile Scale is too small Overlays are not rendered.
Johan Kårlin
Posts: 292
Joined: Wed Jun 03, 2020 11:33 am
Location: Kalmar, Sweden

Re: TilemapEd, Tilemap editor for the X16

Post by Johan Kårlin »

Dacobi wrote: Mon Aug 28, 2023 4:24 pm I'm not sure what you mean by scrollbars? If it's the TileSet editor you mean, the way it works is that you hold down "Left CTRL" and then drag the TileSet with "Left Mouse Button".
That's right, my bad. I had forgot how it works and got confused. It works perfectly well : ).
Dacobi wrote: Tue Aug 29, 2023 1:54 pm I just uploaded TilemapEd version 1.8.99 to GitHub, which has an initial version of Text Overlays.

The Overlays for the TileMap editor are "Tile Values" and "Collision Values" with "Tile Values" being "Tile Index", Flip and if available "Palette Offset".
Awesome! A great help when it comes to finding the right tile to build bigger structures. The only thing I could wish for is that when a tilemap is displayed, tile indices also were displayed on the tiles in the TileSet window. I know that they are in order, tile 0 comes first, then tile 1 and so on. It is just that I find myself looking at the tilemap and find that it is tile 17 I need next. Then I switch focus to the TileSet and find myself counting to find which one is number 17. It would be easier if the indices were overlayed or perhaps displayed above each tile.

As always I am trying to give constructive feedback. It is just my thoughts, you decide what to implement, if it is a good idea, if it is worth the effort etc : ).
Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

As always I am trying to give constructive feedback. It is just my thoughts, you decide what to implement, if it is a good idea, if it is worth the effort etc : ).
Your feedback is always welcome : )

I could probably pretty easily add Tile Indexes to the TileSet window, when the "Tile Values" Overlay is visible or maybe it could have it's own check mark in the "View->Overlay" Menu?
In some ways I'd think it'll be easier to add text overlay than for TileMap/TileSet editor since the TileSet window is an ImGui window which already supports text.

I'd like to hear your thoughts regarding the Overlay text color? This evening I've been working on the "Overlay Text Color" menu, moving it to the "Project" settings instead and adding some more colors. I should be ready with an update tomorrow where the chosen color will be saved to project settings.
Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

I just uploaded TilemapEd version 1.8.108 to GitHib.

The TileSet Window now has an Overlay showing the Tile Index. The Overlay is visible when the TileMap "Tile Values" Overlay is visible or it can be permanently enabled in "View->Overlay->TileSet Index". This value is saved to Project INI.

The Overlay text color can be chosen in "File->Project->Overlay Text Color" and the available colors can be cycled with "CTRL + T".

I'm still not sure if this is the best solution for text visibility, but with the shortcut it's very quick to choose a new color, so I guess it will work.

Overlay Text is now rendered using texture filtering.

These are the available colors:
newcolors.png
newcolors.png (97.11 KiB) Viewed 183734 times
Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

I just uploaded version 1.8.110, where the Overlay Text Size can now be changed in the Project settings along with some other text overlay tweaks and updates.
Johan Kårlin
Posts: 292
Joined: Wed Jun 03, 2020 11:33 am
Location: Kalmar, Sweden

Re: TilemapEd, Tilemap editor for the X16

Post by Johan Kårlin »

Dacobi wrote: Tue Aug 29, 2023 9:15 pm I'd like to hear your thoughts regarding the Overlay text color? This evening I've been working on the "Overlay Text Color" menu, moving it to the "Project" settings instead and adding some more colors. I should be ready with an update tomorrow where the chosen color will be saved to project settings.
Your solution is the best I can think of. It works just fine. It is a good choice to let this be a project setting. The optimal text color will differ between different tilesets.

And the tile indices are now displayed exactly as I wished for. And I like that you just hit TAB and everything is displayed, TAB again all is gone. Thanks for this!
Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

And the tile indices are now displayed exactly as I wished for. And I like that you just hit TAB and everything is displayed, TAB again all is gone. Thanks for this!
Glad to be of service : )

My next project is going to be finishing the "Color Offset" code. I've found this feature to be very useful when creating bitmaps in e.g. Gimp with less than 256 colors, in combination with the Palette Import Sub Range function.

For my game I've made many tiles by creating a bitmap in Gimp with e.g. 32 colors and then exporting both PNG and Gimp palette. Then with the "Color Offset" and Palette Sub Range you can place the 32 colors where you want in the Palette and then Offset the PNG to match.

It's also useful for tiles with BPP 4, e.g. in cases where you need to shift the pixels by '1'.
Last edited by Dacobi on Thu Aug 31, 2023 9:22 am, edited 2 times in total.
Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

I just uploaded version 1.8.114, which has a Project setting to remove "Collision Values" from the <TAB> Toggle shortcut along with some other Overlay tweaks and bugfixes.
Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

I just uploaded version 1.8.125 to GitHub, which has a feature that's been long overdue.

In Win64 "tilemaped.ini" is now being written to "%PROGRAMDATA%\tilemaped\tilemaped.ini" and when the program is first launched from the unzipped folder (also when compiled from source in Linux) the FontPath is written to "tilemaped.ini".
After this the program can be launched from any folder and will read the FontPath from the INI file.
Dacobi
Posts: 292
Joined: Sun Dec 19, 2021 1:44 am
Location: Samsø, Denmark
Contact:

Re: TilemapEd, Tilemap editor for the X16

Post by Dacobi »

I just uploaded version 1.8.128, which has some changes to Win64 INI Path and FontPath.

Since I haven't really used Windows for the last 20 years I don't know much about best practices, but from what I can gather %AppData% is a more appropriate place to put program config files.

So the Win64 INI Path is now "%AppData%\Roaming\tilemaped\tilemaped.ini".

Edit: I just tried running the Win64 binary in Linux under Wine and here the INI path ended up being
"C:\Users\<user name>\Application Data\tilemaped\tilemaped.ini", but if anyone needs to find the actual file the current INI path is shown when running the program from CLI using "-h" or in the "Help Guide" under "About".

Also, FontPath will now be updated in the INI, when the program is launched from the "tilemaped" folder, after this folder has been moved.
Post Reply