Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 2 3 [4] 5 6 ... 9

Author Topic: Extended item viewscreen, custom item descriptions and ASCII art 5.1 beta  (Read 31238 times)

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #45 on: January 22, 2015, 09:44:07 am »

Best to figure out which resolution works best with which size. I could imagine that a 1024 set and a set for 1920 would be reasonable. Same images, just compressed size for the people with smaller screens.

Do you have an extra tileset for this? Like a text-only tileset, or is your ascii image displayed in actual characters/glyphs/text?
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #46 on: January 22, 2015, 10:52:01 am »

Best to figure out which resolution works best with which size. I could imagine that a 1024 set and a set for 1920 would be reasonable. Same images, just compressed size for the people with smaller screens.

Do you have an extra tileset for this? Like a text-only tileset, or is your ascii image displayed in actual characters/glyphs/text?

That is default text tileset for TWBT. Default game with ASCII graphics will have the same look (in text view screen). I did not put any time into making special artwork or tileset variation. People always can manually switch between ascii image sets (i think LNP mod merge will work).
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #47 on: January 22, 2015, 11:24:13 am »

The TWBT, Rendermax and Stonesense demonstrated that you can do something other than putting standard-color glyphs on the screen, though it does require delving into C++.

As with the Dwarf Visualizer, this is the kind of utility that could really, really use a way to blit a bitmapped image onto the DF screen.  Or even a pop-up window from DFHack.  Then there's no need to convert everything into ASCII, and scaling is much easier.

The Rube-Goldberg method would be to put a WTF link on the page that links to a local image file that would appear in the user's default browser.
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #48 on: January 22, 2015, 12:28:57 pm »

The TWBT, Rendermax and Stonesense demonstrated that you can do something other than putting standard-color glyphs on the screen, though it does require delving into C++.

As with the Dwarf Visualizer, this is the kind of utility that could really, really use a way to blit a bitmapped image onto the DF screen.  Or even a pop-up window from DFHack.  Then there's no need to convert everything into ASCII, and scaling is much easier.

The Rube-Goldberg method would be to put a WTF link on the page that links to a local image file that would appear in the user's default browser.

I tried to find a way to paint a colored pixel image, but DFHack screen painting system is too complicated for me, have no idea how to make something actually appear on the screen :) ... Thats a task for DFHack devs, not me (at least at this moment).
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #49 on: January 22, 2015, 12:39:46 pm »

The TWBT, Rendermax and Stonesense demonstrated that you can do something other than putting standard-color glyphs on the screen, though it does require delving into C++.

As with the Dwarf Visualizer, this is the kind of utility that could really, really use a way to blit a bitmapped image onto the DF screen.  Or even a pop-up window from DFHack.  Then there's no need to convert everything into ASCII, and scaling is much easier.

The Rube-Goldberg method would be to put a WTF link on the page that links to a local image file that would appear in the user's default browser.

I tried to find a way to paint a colored pixel image, but DFHack screen painting system is too complicated for me, have no idea how to make something actually appear on the screen :) ... Thats a task for DFHack devs, not me (at least at this moment).
Sorry if I wasn't clear, the idea was for a plugin jockey to suggest something about viewing images.  An image capability that would really helpful to this project, but actually building it is obviously out of scope.
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #50 on: January 22, 2015, 01:40:22 pm »

Regardless of the possibility of actual pictures, I personally would like ascii pics more. They fit the theme of DF better.
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #51 on: January 22, 2015, 10:59:12 pm »


Sorry if I wasn't clear, the idea was for a plugin jockey to suggest something about viewing images.  An image capability that would really helpful to this project, but actually building it is obviously out of scope.

The algorythm may be simple as shit, but i wish somebody explained me how to paint on DF screen using lua syntax :)
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #52 on: January 22, 2015, 11:19:35 pm »

Depends what you mean by "paint".

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #53 on: January 22, 2015, 11:39:18 pm »

Depends what you mean by "paint".

Changing tile characters and color of those characters . (That could also be just DFHack popup with colored tiles instead of text)
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #54 on: January 22, 2015, 11:45:47 pm »

https://github.com/DFHack/dfhack/blob/master/Lua%20API.rst#screen-api

There's a description of the "pen" object there.

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #55 on: January 22, 2015, 11:47:27 pm »

https://github.com/DFHack/dfhack/blob/master/Lua%20API.rst#screen-api

There's a description of the "pen" object there.

Well, I have read that but dont understand how to make it work, though I seem I was successfull at defining a pen :)
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #56 on: January 23, 2015, 12:00:30 am »

You need your own viewscreen, which you can make by just using a table.

It's all kind of confusingly put together, yeah. It probably ought to mention how to make a viewscreen before going into manipulating them.

EDIT: Also, your GetItemTypeID(item) can be replaced with item:getType() and df.item_type[item:getType()].
« Last Edit: January 23, 2015, 12:05:00 am by Putnam »
Logged

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions! v 3.2
« Reply #57 on: January 23, 2015, 12:40:52 am »

EDIT: Also, your GetItemTypeID(item) can be replaced with item:getType() and df.item_type[item:getType()].

I always knew there is an easier way :) thanks
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 4.0 beta
« Reply #58 on: January 25, 2015, 05:42:32 am »

New release! Now with custom ASCII art and item value in adventure mode. Currently there are some inconvenience with images, you need to double-tab to close the image. Also image is only shown if you view description page after general information page. (like monster status in adventure mode, owned buildings list in fortress mode, or item viewscreen)

I will appreciate any code help related to how to recognize what the description belongs to if text viewer screen doesnt have parent view, and how to avoid need for double-tap restriction (so the image is not shown again once you close it)
« Last Edit: January 25, 2015, 05:48:12 am by Raidau »
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

fricy

  • Bay Watcher
  • [DFHACK:ZEALOT]
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 4.0 beta
« Reply #59 on: January 25, 2015, 09:42:49 am »

PTW, great work, also letting you know that 3.2 is in latest Macnewbie.

However: I copied the item_description folder to df/raw and to save/raw, but can't make descriptions appear in game.
Spoiler (click to show/hide)
According to debug mode this is the path the script tries to access:
Code: [Select]
/Applications/Macnewbie_9.16/Macnewbie/Dwarf Fortress/data/save/region3-lowfps\raw\item_descriptions\WEAPON\ITEM_WEAPON_AXE_BATTLE.txtNote the difference in slashes after data/save/ I suspect this issue is present on linux too.

A different issue is with material properties illustrated here:
Spoiler (click to show/hide)
Those long lines need to be formatted differently to be usable.
Pages: 1 2 3 [4] 5 6 ... 9