Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 6 7 [8] 9

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

lethosor

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 4.2 beta
« Reply #105 on: January 30, 2015, 04:07:16 pm »

There's more than one LNP, and things like that should generally be posted in the thread for the pack you use. This script is intended to replace the item info screen, and there doesn't seem to be a way to disable it besides removing it from dfhack.init and restarting DF.
Edit: Of course, this script shouldn't be blocking the thoughts and preferences screen (and a bug report is perfectly fine in this thread).
« Last Edit: January 30, 2015, 04:09:50 pm by lethosor »
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 4.2 beta
« Reply #106 on: January 30, 2015, 11:56:42 pm »

obviously you've put a lot of work into this and its seems well received by the experienced players in the community;

 however it is included in the LNP and is on by default. I couldn't work out how to turn it off.

I looked at a dwarfs thoughts and preferences and couldn't get out of the screen. all I saw was ascii art (over the text I wanted to read) and some text at top and bottom "dfhack" and "ascii view". no "esc = exit" which I saw in this thread and may be a more recent addition. when I googled "dfhack ascii view turn off" I wasn't able to find anything.

finally found this thread after half an hour.

You must edit dfhack.init and find "nb_item_info" string, then check what arguments are there. If you dont want to see dwarf's ascii just remove "ascii_unit" argument from there.

ASCII images are now closed by double-tap of the key you use to leave the screen.

PeridexisErrant, could you move the script setting into dfhack setting panel in the launcher? Also unit's ascii graphics should be turned off for now by default, its not finished and cause inconvenience.
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

palu

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 4.2 beta
« Reply #107 on: January 31, 2015, 12:18:34 am »

This is amazing! PTW.
Logged
Hmph, palu showing off that reading-the-instructions superpower.
The internet encourages thoughtful, intelligent discussion and if you disagree I hate you.

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 5.1 beta
« Reply #108 on: January 31, 2015, 03:51:08 am »

I have updated the DFFD release. All vanilla description blanks included, as well as df tile ascii format.

Celsius temperature is now displayed along with Urist scale. Degree sign added :)
« Last Edit: January 31, 2015, 04:09:51 am by Raidau »
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Deon

  • Bay Watcher
  • 💀 💀 💀 💀 💀
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 5.1 beta
« Reply #109 on: January 31, 2015, 04:51:28 am »

I've just realised that I can use it to make in-game tutorials for custom workshops. You can simply make a "chemistry manual" item and add all reagents/reactions/descriptions to its description.
Logged
▬(ஜ۩۞۩ஜ)▬
✫ DF Wanderer ✫ - the adventure mode crafting and tweaks
✫ Cartographer's Lounge ✫ - a custom worldgen repository

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 5.1 beta
« Reply #110 on: January 31, 2015, 05:08:26 am »

I've just realised that I can use it to make in-game tutorials for custom workshops. You can simply make a "chemistry manual" item and add all reagents/reactions/descriptions to its description.

Great idea, BTW. It can be just tool. Or you can make special inorganic and create a BOOK item made of that material. It will contain specific description as well. (I think this can be used with books created by scripts or some reactions). But I think WTF Editor is better for general manuals.
« Last Edit: January 31, 2015, 05:12:39 am by Raidau »
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

Deon

  • Bay Watcher
  • 💀 💀 💀 💀 💀
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 5.1 beta
« Reply #111 on: February 01, 2015, 06:08:14 am »

Well the material is going to be paper, that's for sure. I will just make different tool types, that's it. Can you please introduce some kind of a "parameter" system so we could omit material properties/temperature/sharpness selectively for specific items/materials. I.e. I want this information for weapons but don't want for musical instruments.
Logged
▬(ஜ۩۞۩ஜ)▬
✫ DF Wanderer ✫ - the adventure mode crafting and tweaks
✫ Cartographer's Lounge ✫ - a custom worldgen repository

Raidau

  • Bay Watcher
    • View Profile
Re: Extended item viewscreen, custom item descriptions and ASCII art 5.1 beta
« Reply #112 on: February 01, 2015, 07:55:13 am »

Well the material is going to be paper, that's for sure. I will just make different tool types, that's it. Can you please introduce some kind of a "parameter" system so we could omit material properties/temperature/sharpness selectively for specific items/materials. I.e. I want this information for weapons but don't want for musical instruments.

There is such parameter. Currenly script shows material info only for certain item types (namely weapons, bars, armor, leather, stone, tools, and all subtypes of those types), so all tools will have that large material tooltip... I can fix this if you wish, i think this will require an additional config file with all the exceptions
Logged
Marital status manipulator
Custom item descriprions
Natural Balance Mod (2013-2015) development suspended...

PeridexisErrant

  • Bay Watcher
  • Dai stihó, Hrasht.
    • View Profile

Any further news on development?  It went silent a month ago, and I'm starting to wonder if something happened! 

There are a couple of changes I'd love to see, and could try working on myself:
  • Add it to the DFHack standard library; style changes required (and content storage??)
  • Set and enforce a standard size for art; cropping if over and padding if under.
  • Find an alternative way of storing descriptions and art.  Currently it gets wiped out by PyLNP with every mod or graphics change - it would be great to store in a single file in hack/scripts/, and have some clever way for mods to add content without overlapping.

If I don't hear back soonish I'll get to work, but it's better to contribute than fork if you can  :)
Logged
I maintain the DF Starter Pack - over a million downloads and still counting!
 Donations here.

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile

Hmmm, was just gonna ask if anyone knew what to do if you happened to encounter something made of slade or dfhacked say, a war hammer into slade to see what difference it made over platinum and it spits this every time you view the item:
Code: [Select]
/home/thefunk/.df24/hack/scripts/nb_item_info.lua:486: Cannot read field vector<descriptor_color*>.-1: index out of bounds.
stack traceback:
        [C]: in function '__index'
        /home/thefunk/.df24/hack/scripts/nb_item_info.lua:486: in function 'GetMatPropertiesStringList'
        /home/thefunk/.df24/hack/scripts/nb_item_info.lua:953: in function </home/thefunk/.df24/hack/scripts/nb_item_info.lua:841>

I tried to figure out where to add a connection but I can't figure out the layout well enough, and I think it might be related to slade having the 0,0,1 color making the nb item info script throw the error.
Logged

lethosor

  • Bay Watcher
    • View Profile

Quote
vector<descriptor_color*>.-1
I haven't tried to track this down, but errors like these are typically caused by attempting to use df.some_enum.NONE (usually -1) as an array index.
« Last Edit: March 09, 2015, 10:07:19 pm by lethosor »
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile

descriptor_color certainly isn't an enum, being a raw object.

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile

Well, it's an edge case that it pops up in anyways, so I can see why it wasn't bugging anyone else enough to bring it up if it was even noticed. How many slade war hammers you got laying around most of the time, right?

Didn't see if it pops up when you check an underworld vault and see the slade there or not actually.
Logged

PeridexisErrant

  • Bay Watcher
  • Dai stihó, Hrasht.
    • View Profile

So, I've been working on a vanilla-DF port.  If anyone wants to test it, that would be awesome!

view-item-info.lua is a lot less complicated, due to a huge refactor that also dropped support for the NB mod, images and custom descriptions.  I plan to add custom descriptions back in later, with a function designed for a sparse data set.  I'll also re-implement mod support (as soon as someone asks me to) using /raw/scripts/ to allow incremental development, since I think the challenge put people off before.

I've replaced all the magic numbers, too - all that's left is   viewscreen.unk_34:insert('#', nil)  ... and since I don't even understand what it's doing, so someone else might have to translate into usable structures research.
Logged
I maintain the DF Starter Pack - over a million downloads and still counting!
 Donations here.

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile

Good news: after dfhacking a steel axe artifact into slade and checking it with vb-item-info enabled it doesn't spit errors.

Bad news: it doesn't show a description either, oh and it kinda adds new copies of the value entry each time you enter and exit the detail screen.
Logged
Pages: 1 ... 6 7 [8] 9